Trait ActorSystemHandle

Source
pub trait ActorSystemHandle: DynClone + Send {
    type ActorRefT<MsgT>: ActorRef<MsgT>
       where MsgT: ActorMsg;

    // Required method
    fn create<MsgT>(
        &self,
        node_id: impl Into<String>,
        name: impl Into<String>,
        join_on_drop: bool,
    ) -> Self::ActorRefT<MsgT>
       where MsgT: ActorMsg;
}
Expand description

An ActorSystemHandle allows spawning actors by creating an ActorRef and it can be cloned. Actors themselves can use ActorSystemHandles to spawn new actors.

Required Associated Types§

Source

type ActorRefT<MsgT>: ActorRef<MsgT> where MsgT: ActorMsg

Required Methods§

Source

fn create<MsgT>( &self, node_id: impl Into<String>, name: impl Into<String>, join_on_drop: bool, ) -> Self::ActorRefT<MsgT>
where MsgT: ActorMsg,

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.

Implementors§