pub trait ProcSpawnerEndpoint {
// Provided methods
fn spawn_proc(&self, cx: &impl Actor) -> Result<ActorRef<SpawnActor>>
where Self: Clone + Send + 'static,
for<'a> &'a Self: Endpoint<SpawnProcMessage> { ... }
fn spawn_proc_uid(
&self,
cx: &impl Actor,
uid: Uid,
) -> Result<ActorRef<SpawnActor>>
where Self: Clone + Send + 'static,
for<'a> &'a Self: Endpoint<SpawnProcMessage> { ... }
fn spawn_proc_uid_with_ready(
&self,
cx: &impl Actor,
uid: Uid,
ready: OncePortHandle<()>,
) -> Result<ActorRef<SpawnActor>>
where Self: Clone + Send + 'static,
for<'a> &'a Self: Endpoint<SpawnProcMessage> { ... }
fn spawn_proc_uid_with_link(
&self,
cx: &impl Actor,
uid: Uid,
liveness: KeepaliveLink,
) -> Result<ActorRef<SpawnActor>>
where Self: Clone + Send + 'static,
for<'a> &'a Self: Endpoint<SpawnProcMessage> { ... }
fn spawn_proc_uid_with_link_and_ready(
&self,
cx: &impl Actor,
uid: Uid,
liveness: KeepaliveLink,
ready: Option<OncePortHandle<()>>,
) -> Result<ActorRef<SpawnActor>>
where Self: Clone + Send + 'static,
for<'a> &'a Self: Endpoint<SpawnProcMessage> { ... }
}Expand description
Convenience methods for endpoints that accept SpawnProc requests.
Provided Methods§
Sourcefn spawn_proc(&self, cx: &impl Actor) -> Result<ActorRef<SpawnActor>>
fn spawn_proc(&self, cx: &impl Actor) -> Result<ActorRef<SpawnActor>>
Spawn a proc with a fresh proc uid.
Sourcefn spawn_proc_uid(
&self,
cx: &impl Actor,
uid: Uid,
) -> Result<ActorRef<SpawnActor>>
fn spawn_proc_uid( &self, cx: &impl Actor, uid: Uid, ) -> Result<ActorRef<SpawnActor>>
Spawn a proc with an explicit proc uid.
Sourcefn spawn_proc_uid_with_ready(
&self,
cx: &impl Actor,
uid: Uid,
ready: OncePortHandle<()>,
) -> Result<ActorRef<SpawnActor>>
fn spawn_proc_uid_with_ready( &self, cx: &impl Actor, uid: Uid, ready: OncePortHandle<()>, ) -> Result<ActorRef<SpawnActor>>
Spawn a proc and report when it becomes reachable.
The returned ActorRef names the proc’s actor-spawn endpoint, but the
proc has to launch and join before that endpoint can route — messages
sent earlier are dropped. A bare readiness signal is posted to ready
once the proc has joined, so callers that need to use the endpoint can
wait for that signal instead of guessing with a delay. The endpoint
address is already known from the synchronously returned ActorRef, so
ready carries no payload.
Sourcefn spawn_proc_uid_with_link(
&self,
cx: &impl Actor,
uid: Uid,
liveness: KeepaliveLink,
) -> Result<ActorRef<SpawnActor>>
fn spawn_proc_uid_with_link( &self, cx: &impl Actor, uid: Uid, liveness: KeepaliveLink, ) -> Result<ActorRef<SpawnActor>>
Spawn a proc with an explicit proc uid and liveness link.
Sourcefn spawn_proc_uid_with_link_and_ready(
&self,
cx: &impl Actor,
uid: Uid,
liveness: KeepaliveLink,
ready: Option<OncePortHandle<()>>,
) -> Result<ActorRef<SpawnActor>>
fn spawn_proc_uid_with_link_and_ready( &self, cx: &impl Actor, uid: Uid, liveness: KeepaliveLink, ready: Option<OncePortHandle<()>>, ) -> Result<ActorRef<SpawnActor>>
Spawn a proc with an explicit proc uid, liveness link, and optional
readiness port. This is the general form behind the other spawn_proc*
methods; see spawn_proc_uid_with_ready
for the readiness semantics.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".