Skip to main content

ChildRoute

Struct ChildRoute 

Source
pub struct ChildRoute<Child: Behavior, Role> { /* private fields */ }
Expand description

A named creator-local route for one statically declared child role.

The route carries routing intent only. Its nonce is not an actor identity, proof of freshness, or evidence that creation succeeded. Child fixes the exact behavior accepted by ChildRoute::birth, while Role keeps two declarations of the same child behavior nominally distinct.

Implementations§

Source§

impl<Child: Behavior, Role> ChildRoute<Child, Role>

Source

pub const fn new( nonce: <<Child::Protocol as Protocol>::Addr as Address>::Nonce, ) -> Self

Name this declared role at a creator-local route.

Source

pub const fn recipient(self) -> ChildRecipient<Child::Protocol>

Return the creator-local recipient for this declared child role.

Source

pub const fn nonce( self, ) -> <<Child::Protocol as Protocol>::Addr as Address>::Nonce

Return the creator-local nonce used by creation and lifecycle facts.

Source

pub const fn stage( self, child: Child, kind: CreationKind<<<Child::Protocol as Protocol>::Addr as Address>::Nonce>, ) -> Create<<Child::Protocol as Protocol>::Addr, Child>

Stage one creation request with explicit Behavior-owned provenance.

Source

pub const fn birth( self, child: Child, ) -> Create<<Child::Protocol as Protocol>::Addr, Child>

Stage an ordinary fresh-birth request for this declared child role.

Source

pub const fn replacement_incarnation( self, replaces: <<Child::Protocol as Protocol>::Addr as Address>::Nonce, child: Child, ) -> Create<<Child::Protocol as Protocol>::Addr, Child>

Stage a replacement incarnation for this declared child role.

Trait Implementations§

Source§

impl<Child: Behavior, Role> Clone for ChildRoute<Child, Role>

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<Child: Behavior, Role> Copy for ChildRoute<Child, Role>

Source§

impl<Child: Behavior, Role> Debug for ChildRoute<Child, Role>
where <<Child::Protocol as Protocol>::Addr as Address>::Nonce: Debug,

Source§

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

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

impl<Child: Behavior, Role> Eq for ChildRoute<Child, Role>

Source§

impl<Child: Behavior, Role> PartialEq for ChildRoute<Child, Role>

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more

Auto Trait Implementations§

§

impl<Child, Role> Freeze for ChildRoute<Child, Role>
where <<<Child as Behavior>::Protocol as Protocol>::Addr as Address>::Nonce: Freeze,

§

impl<Child, Role> RefUnwindSafe for ChildRoute<Child, Role>
where <<<Child as Behavior>::Protocol as Protocol>::Addr as Address>::Nonce: RefUnwindSafe,

§

impl<Child, Role> Send for ChildRoute<Child, Role>
where <<<Child as Behavior>::Protocol as Protocol>::Addr as Address>::Nonce: Send,

§

impl<Child, Role> Sync for ChildRoute<Child, Role>
where <<<Child as Behavior>::Protocol as Protocol>::Addr as Address>::Nonce: Sync,

§

impl<Child, Role> Unpin for ChildRoute<Child, Role>
where <<<Child as Behavior>::Protocol as Protocol>::Addr as Address>::Nonce: Unpin,

§

impl<Child, Role> UnsafeUnpin for ChildRoute<Child, Role>
where <<<Child as Behavior>::Protocol as Protocol>::Addr as Address>::Nonce: UnsafeUnpin,

§

impl<Child, Role> UnwindSafe for ChildRoute<Child, Role>
where <<<Child as Behavior>::Protocol as Protocol>::Addr as Address>::Nonce: UnwindSafe,

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> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

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> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
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.