pub trait ReactorInitializer: ReactorBehavior {
type Wrapped;
type Params;
const MAX_REACTION_ID: LocalReactionId;
// Required method
fn assemble(
args: Self::Params,
assembler: AssemblyCtx<'_, Self>,
) -> AssemblyResult<FinishedReactor<'_, Self>>
where Self: Sized;
}Expand description
Wrapper around the user struct for safe dispatch.
Fields are
- the user struct,
- ctor parameters of the reactor, and
- every logical action and port declared by the reactor.
Required Associated Constants§
Sourceconst MAX_REACTION_ID: LocalReactionId
const MAX_REACTION_ID: LocalReactionId
Exclusive maximum value of the local_rid parameter of [ReactorBehavior.react].
Required Associated Types§
Required Methods§
Sourcefn assemble(
args: Self::Params,
assembler: AssemblyCtx<'_, Self>,
) -> AssemblyResult<FinishedReactor<'_, Self>>where
Self: Sized,
fn assemble(
args: Self::Params,
assembler: AssemblyCtx<'_, Self>,
) -> AssemblyResult<FinishedReactor<'_, Self>>where
Self: Sized,
Assemble this reactor. This initializes state variables, produces internal components, assembles children reactor instances, and declares dependencies between them.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.