Trait vin_core::TaskAddr

source ·
pub trait TaskAddr {
    // Required methods
    fn close(&self);
    fn close_future(&self) -> Notified<'_>;
    fn state(&self) -> State;
    fn id(&self) -> String;

    // Provided method
    fn is_closed(&self) -> bool { ... }
}
Expand description

A restricted interface of TaskActor that provides closing and state reads.

Required Methods§

source

fn close(&self)

Sends a close signal to the task actor.

source

fn close_future(&self) -> Notified<'_>

Returns this task actor’s close future.

source

fn state(&self) -> State

Returns the state of the task actor.

source

fn id(&self) -> String

Returns the id of the task actor.

Provided Methods§

source

fn is_closed(&self) -> bool

Returns if the task actor is closed.

Implementors§