[−][src]Struct xtra::ActorManager
A manager for the actor which handles incoming messages and stores the context. Its managing
loop can be started with ActorManager::manage
.
Implementations
impl<A: Actor> ActorManager<A>
[src]
pub async fn manage(__arg0: Self)
[src]
Starts the manager loop. This will start the actor and allow it to respond to messages.
Example
struct MyActor; impl Actor for MyActor {} #[smol_potat::main] async fn main() { let (addr, mgr) = MyActor.create(); smol::Task::spawn(mgr.manage()).detach(); // Actually spawn the actor onto an executor }
Trait Implementations
Auto Trait Implementations
impl<A> !RefUnwindSafe for ActorManager<A>
impl<A> Send for ActorManager<A> where
A: Send,
A: Send,
impl<A> !Sync for ActorManager<A>
impl<A> Unpin for ActorManager<A> where
A: Unpin,
A: Unpin,
impl<A> !UnwindSafe for ActorManager<A>
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,
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.
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>,