Enum ark_api::behavior::IncomingMessageAddr
source · [−]pub enum IncomingMessageAddr {
Behavior(BehaviorAddr),
Module(Option<ForeignBehaviorInstanceId>),
}
Expand description
Target address of an incoming message.
Variants
Behavior(BehaviorAddr)
The message is targeted at a specific behavior instance.
Module(Option<ForeignBehaviorInstanceId>)
This incoming message is targeted at the behavior module itself.
Implementations
sourceimpl IncomingMessageAddr
impl IncomingMessageAddr
sourcepub fn from_raw(actor_id: ActorId, instance: ForeignBehaviorInstanceId) -> Self
pub fn from_raw(actor_id: ActorId, instance: ForeignBehaviorInstanceId) -> Self
Creates a new IncomingMessageAddr
given its raw components.
sourcepub fn unwrap_behavior(&self) -> BehaviorAddr
pub fn unwrap_behavior(&self) -> BehaviorAddr
Assuming a message targeted at a behavior, unwraps it and extracts its components.
Trait Implementations
sourceimpl Debug for IncomingMessageAddr
impl Debug for IncomingMessageAddr
sourceimpl PartialEq<IncomingMessageAddr> for IncomingMessageAddr
impl PartialEq<IncomingMessageAddr> for IncomingMessageAddr
sourcefn eq(&self, other: &IncomingMessageAddr) -> bool
fn eq(&self, other: &IncomingMessageAddr) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
impl Eq for IncomingMessageAddr
impl StructuralEq for IncomingMessageAddr
impl StructuralPartialEq for IncomingMessageAddr
Auto Trait Implementations
impl RefUnwindSafe for IncomingMessageAddr
impl Send for IncomingMessageAddr
impl Sync for IncomingMessageAddr
impl Unpin for IncomingMessageAddr
impl UnwindSafe for IncomingMessageAddr
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more