Struct theatre::actors::supervisor::Supervisor [−][src]
Supervisor is an actor that can catch panics in other actors.
To supervisor an actor, start a supervisor and then pass the structure to the supervisor with
the message SuperviseActor(...)
,
Implementations
impl Supervisor
[src]
pub fn new() -> Self
[src]
pub async fn supervise<A>(&mut self, actor: A) -> (Addr<A>, ActorHandle) where
A: 'static + Supervised,
[src]
A: 'static + Supervised,
Trait Implementations
impl Actor for Supervisor
[src]
#[must_use]fn starting<'life0, 'life1, 'async_trait>(
&'life0 mut self,
_ctx: &'life1 mut Context<Self>
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>> where
Self: Sized,
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
[src]
&'life0 mut self,
_ctx: &'life1 mut Context<Self>
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>> where
Self: Sized,
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
#[must_use]fn stopping<'life0, 'life1, 'async_trait>(
&'life0 mut self,
_ctx: &'life1 mut Context<Self>
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>> where
Self: Sized,
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
[src]
&'life0 mut self,
_ctx: &'life1 mut Context<Self>
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>> where
Self: Sized,
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
#[must_use]fn stopped<'life0, 'life1, 'async_trait>(
&'life0 mut self,
_ctx: &'life1 mut Context<Self>
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>> where
Self: Sized,
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
[src]
&'life0 mut self,
_ctx: &'life1 mut Context<Self>
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>> where
Self: Sized,
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
impl Debug for Supervisor
[src]
impl Default for Supervisor
[src]
fn default() -> Supervisor
[src]
impl<A> Handler<SuperviseActor<A>> for Supervisor where
A: 'static + Actor + Supervised,
[src]
A: 'static + Actor + Supervised,
Auto Trait Implementations
impl RefUnwindSafe for Supervisor
impl Send for Supervisor
impl Sync for Supervisor
impl Unpin for Supervisor
impl UnwindSafe for Supervisor
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,