pub struct RootActorMesh<'a, A: Referable> { /* private fields */ }Expand description
A mesh of actor instances. ActorMeshes are obtained by spawning an
actor on a ProcMesh.
Generic bound: A: Referable — this type hands out typed
ActorRef<A> handles (see ranks), and ActorRef is only
defined for A: Referable.
Implementations§
Source§impl<'a, A: Referable> RootActorMesh<'a, A>
impl<'a, A: Referable> RootActorMesh<'a, A>
pub fn new_v1(actor_mesh: ActorMeshRef<A>) -> Self
Sourcepub fn open_port<M: Message>(&self) -> (PortHandle<M>, PortReceiver<M>)
pub fn open_port<M: Message>(&self) -> (PortHandle<M>, PortReceiver<M>)
Open a port on this ActorMesh.
Sourcepub fn events(&mut self) -> Option<ActorSupervisionEvents>
pub fn events(&mut self) -> Option<ActorSupervisionEvents>
An event stream of actor events. Each RootActorMesh can produce only one such stream, returning None after the first call.
Trait Implementations§
Source§impl<A: Referable> ActorMesh for RootActorMesh<'_, A>
impl<A: Referable> ActorMesh for RootActorMesh<'_, A>
Source§fn v1(&self) -> Option<ActorMeshRef<Self::Actor>>
fn v1(&self) -> Option<ActorMeshRef<Self::Actor>>
Retrieves the v1 mesh for this v0 ActorMesh, if it is available.
Source§fn cast<M>(
&self,
cx: &impl Actor,
selection: Selection,
message: M,
) -> Result<(), CastError>where
Self::Actor: RemoteHandles<M> + RemoteHandles<IndexedErasedUnbound<M>>,
M: Castable + RemoteMessage + Clone,
fn cast<M>(
&self,
cx: &impl Actor,
selection: Selection,
message: M,
) -> Result<(), CastError>where
Self::Actor: RemoteHandles<M> + RemoteHandles<IndexedErasedUnbound<M>>,
M: Castable + RemoteMessage + Clone,
Cast an
M-typed message to the ranks selected by sel in
this ActorMesh.fn world_id(&self) -> &WorldId
Source§fn iter_actor_refs(&self) -> Box<dyn Iterator<Item = ActorRef<Self::Actor>>>
fn iter_actor_refs(&self) -> Box<dyn Iterator<Item = ActorRef<Self::Actor>>>
Iterate over all
ActorRef<Self::Actor> in this mesh.fn stop<'life0, 'life1, 'async_trait>(
&'life0 self,
cx: &'life1 (impl 'async_trait + Actor),
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Source§fn bind(&self) -> ActorMeshRef<Self::Actor>
fn bind(&self) -> ActorMeshRef<Self::Actor>
Get a serializeable reference to this mesh similar to ActorHandle::bind
Source§impl<'a, A: Referable> From<ActorMeshRef<A>> for RootActorMesh<'a, A>
impl<'a, A: Referable> From<ActorMeshRef<A>> for RootActorMesh<'a, A>
Source§fn from(actor_mesh: ActorMeshRef<A>) -> Self
fn from(actor_mesh: ActorMeshRef<A>) -> Self
Converts to this type from the input type.
Source§impl<'a, A: Referable> Mesh for RootActorMesh<'a, A>
impl<'a, A: Referable> Mesh for RootActorMesh<'a, A>
Source§type Id = ActorMeshId
type Id = ActorMeshId
The type of identifiers for this mesh.
Source§type Sliced<'b> = SlicedActorMesh<'b, A>
where
'a: 'b
type Sliced<'b> = SlicedActorMesh<'b, A> where 'a: 'b
The type of a slice of this mesh. Slices should not outlive their
parent mesh.
Source§fn select<R: Into<Range>>(
&self,
label: &str,
range: R,
) -> Result<Self::Sliced<'_>, ShapeError>
fn select<R: Into<Range>>( &self, label: &str, range: R, ) -> Result<Self::Sliced<'_>, ShapeError>
Sub-slice this mesh, specifying the included ranges for
the dimension with the labeled name.
Auto Trait Implementations§
impl<'a, A> !Freeze for RootActorMesh<'a, A>
impl<'a, A> !RefUnwindSafe for RootActorMesh<'a, A>
impl<'a, A> Send for RootActorMesh<'a, A>
impl<'a, A> Sync for RootActorMesh<'a, A>
impl<'a, A> Unpin for RootActorMesh<'a, A>where
A: Unpin,
impl<'a, A> !UnwindSafe for RootActorMesh<'a, A>
Blanket Implementations§
§impl<T> AnySync for T
impl<T> AnySync for T
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Source§impl<A, M> Handler<IndexedErasedUnbound<M>> for A
impl<A, M> Handler<IndexedErasedUnbound<M>> for A
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more