[][src]Struct riker::actors::ActorSystem

pub struct ActorSystem<Msg: Message> {
    pub proto: Arc<ProtoSystem>,
    pub kernel: Option<KernelRef<Msg>>,
    pub event_store: Option<ActorRef<Msg>>,
    pub sys_channels: Option<SysChannels<Msg>>,
    // some fields omitted
}

The actor runtime and common services coordinator

The ActorSystem provides a runtime on which actors are executed. It also provides common services such as channels, persistence and scheduling. The ActorSystem is the heart of a Riker application, starting serveral threads when it is created. Create only one instance of ActorSystem per application.

Fields

Methods

impl<Msg: Message> ActorSystem<Msg>
[src]

Create a new ActorSystem instance

Requires a type that implements the Model trait.

Create a new ActorSystem instance with provided name

Requires a type that implements the Model trait.

Create a new ActorSystem instance bypassing default config behavior

Requires a type that implements the Model trait.

Shutdown the actor system

Attempts a graceful shutdown of the system and all actors. Actors will receive a stop message, executing actor.post_stop.

Does not block. Returns a future which is completed when all actors have successfully stopped.

Returns the system start date

Returns the number of seconds since the system started

Returns the hostname used when the system started

The host is used in actor addressing.

Currently not used, but will be once system clustering is introduced.

Returns the UUID assigned to the system

Returns the name of the system

Returns the user root actor reference

Returns the system root actor reference

Reutrns the temp root actor reference

Returns a reference to the default stream channel

Returns a reference to the event stream channel

Returns a reference to the dead letters channel

Returns a reference to the IO Manager

Returns the Config used by the system

Create an actor under the system root

Trait Implementations

impl<Msg> ActorRefFactory for ActorSystem<Msg> where
    Msg: Message
[src]

impl<Msg> TmpActorRefFactory for ActorSystem<Msg> where
    Msg: Message
[src]

impl<Msg> ActorSelectionFactory for ActorSystem<Msg> where
    Msg: Message
[src]

impl<Msg> Timer for ActorSystem<Msg> where
    Msg: Message
[src]

impl<Msg> ExecutionContext for ActorSystem<Msg> where
    Msg: Message
[src]

impl<Msg: Message> Send for ActorSystem<Msg>
[src]

impl<Msg: Clone + Message> Clone for ActorSystem<Msg>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl<Msg: Message> Sync for ActorSystem<Msg>
[src]

impl<Msg> Debug for ActorSystem<Msg> where
    Msg: Message
[src]

Formats the value using the given formatter. Read more

Blanket Implementations

impl<T> From for T
[src]

Performs the conversion.

impl<T, U> Into for T where
    U: From<T>, 
[src]

Performs the conversion.

impl<T> ToOwned for T where
    T: Clone
[src]

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

impl<T, U> TryFrom for T where
    T: From<U>, 
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

impl<T> Borrow for T where
    T: ?Sized
[src]

Immutably borrows from an owned value. Read more

impl<T> Any for T where
    T: 'static + ?Sized
[src]

🔬 This is a nightly-only experimental API. (get_type_id)

this method will likely be replaced by an associated static

Gets the TypeId of self. Read more

impl<T> BorrowMut for T where
    T: ?Sized
[src]

Mutably borrows from an owned value. Read more

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.