Skip to main content

DispatchBirth

Trait DispatchBirth 

Source
pub trait DispatchBirth<A: Address, Installer, Output, Error>: Sized {
    // Required method
    fn dispatch_birth(
        self,
        nonce: A::Nonce,
        kind: CreationKind<A::Nonce>,
        installer: &mut Installer,
    ) -> impl Future<Output = Result<Output, Error>> + Send;
}
Expand description

Exhaustive static dispatch of one creation-only child sum.

This is an interpreter-facing derived construction, not another actor-model operation. Implementations must preserve the nonce and provenance and call exactly one concrete InstallBirth implementation. ChildChoice provides the closed recursive heterogeneous sum. Dispatch futures are sendable; heterogeneous sums therefore require sendable alternatives, creator-local nonces, and installers.

Required Methods§

Source

fn dispatch_birth( self, nonce: A::Nonce, kind: CreationKind<A::Nonce>, installer: &mut Installer, ) -> impl Future<Output = Result<Output, Error>> + Send

Select exactly one concrete installer while preserving creation data.

§Errors

Returns the selected concrete installer’s typed failure unchanged.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<A, C, Installer, Output, Error> DispatchBirth<A, Installer, Output, Error> for C
where A: Address, C: Behavior, C::Protocol: Protocol<Addr = A>, Installer: InstallBirth<A, C, Output, Error>,

Source§

impl<A, Head, Tail, Installer, Output, Error> DispatchBirth<A, Installer, Output, Error> for ChildChoice<Head, Tail>
where A: Address, A::Nonce: Send, Head: Behavior + Send, Head::Protocol: Protocol<Addr = A>, Tail: DispatchBirth<A, Installer, Output, Error> + Send, Installer: InstallBirth<A, Head, Output, Error> + Send,

Source§

impl<A, Installer, Output, Error> DispatchBirth<A, Installer, Output, Error> for Never
where A: Address,