Skip to main content

WebCodegenRequest

Struct WebCodegenRequest 

Source
pub struct WebCodegenRequest {
Show 25 fields pub config_path: PathBuf, pub output_dir: PathBuf, pub project_root: PathBuf, pub overwrite_user_code: bool, pub package_name: String, pub manufacturer: String, pub actr_name: String, pub version: String, pub description: String, pub authors: Vec<String>, pub license: String, pub tags: Vec<String>, pub signaling_url: String, pub realm_id: u32, pub visible_in_discovery: bool, pub ais_endpoint: String, pub force_relay: bool, pub dependencies: Vec<DependencyInfo>, pub stun_urls: Vec<String>, pub turn_urls: Vec<String>, pub observability: ObservabilityInfo, pub raw_toml: String, pub local_services: Vec<ServiceInfo>, pub remote_services: Vec<ServiceInfo>, pub files: Vec<FileInfo>,
}
Expand description

Complete request from CLI to plugin

Fields§

§config_path: PathBuf

Path to actr.toml (used for reading raw TOML extras)

§output_dir: PathBuf

Output directory for generated TS files (e.g. src/generated)

§project_root: PathBuf

Project root directory (parent of src/)

§overwrite_user_code: bool

Whether already-existing user code may be overwritten

§package_name: String§manufacturer: String§actr_name: String§version: String§description: String§authors: Vec<String>§license: String§tags: Vec<String>§signaling_url: String§realm_id: u32§visible_in_discovery: bool§ais_endpoint: String

AIS (Actor Identity Service) HTTP endpoint

§force_relay: bool

Whether to force relay (TURN-only) for ICE transport

§dependencies: Vec<DependencyInfo>§stun_urls: Vec<String>§turn_urls: Vec<String>§observability: ObservabilityInfo§raw_toml: String§local_services: Vec<ServiceInfo>§remote_services: Vec<ServiceInfo>§files: Vec<FileInfo>

Implementations§

Source§

impl WebCodegenRequest

Source

pub fn is_service_provider_only(&self) -> bool

Whether this project exports services only and does not call out to any remote actor. Used by the WASM scaffold generator to decide whether to emit a service handler (provider) or a forwarding stub.

Note: this is purely a codegen topology signal derived from the proto model — it does NOT imply a passive connection role. Any actor can be called by any other actor; connection initiator / acceptor roles are negotiated per-peer at runtime.

Source

pub fn get_acl_allow_types(&self) -> Vec<String>

Get ACL allow types from raw TOML

Source

pub fn target_actr_type(&self) -> String

Get the target actr type for peer discovery (manufacturer:name:version).

For an actor that imports a remote service, the target is the declared dependency. For an actor that only exports services, the target is the first ACL-allowed type — useful for RPCs initiated from that actor side when it needs to reach a caller by type.

Source

pub fn client_actr_type(&self) -> String

Get client actr type (this actor’s type) — manufacturer:name:version

Source

pub fn wasm_module_name(&self) -> String

Get crate/WASM module name (snake_case)

Source

pub fn edition(&self) -> i64

Get edition from raw TOML

Source

pub fn exports_list(&self) -> Vec<String>

Get exports from raw TOML

Source

pub fn platform_web(&self) -> Option<Value>

Get platform.web from raw TOML

Source

pub fn raw_acl(&self) -> Option<Value>

Get raw ACL value from TOML

Trait Implementations§

Source§

impl Debug for WebCodegenRequest

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for WebCodegenRequest

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Serialize for WebCodegenRequest

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,