[−][src]Struct riker::actor::Props
Provides instances of ActorProducer
for use when creating Actors (actor_of
).
Actors are not created directly. Instead you provide an ActorProducer
that allows the ActorSystem
to start an actor when actor_of
is used,
or when an actor fails and a supervisor requests an actor to be restarted.
ActorProducer
can hold values required by the actor's factory method
parameters.
Methods
impl Props
[src]
pub fn new<A, F>(creator: F) -> Arc<Mutex<impl ActorProducer<Actor = A>>> where
A: Actor + Send + 'static,
F: Fn() -> A + Send + 'static,
[src]
A: Actor + Send + 'static,
F: Fn() -> A + Send + 'static,
Creates an ActorProducer
with no factory method parameters.
pub fn new_args<A, Args, F>(
creator: F,
args: Args
) -> Arc<Mutex<impl ActorProducer<Actor = A>>> where
A: Actor + Send + 'static,
Args: ActorArgs + 'static,
F: Fn(Args) -> A + Send + 'static,
[src]
creator: F,
args: Args
) -> Arc<Mutex<impl ActorProducer<Actor = A>>> where
A: Actor + Send + 'static,
Args: ActorArgs + 'static,
F: Fn(Args) -> A + Send + 'static,
Creates an ActorProducer
with one or more factory method parameters.
Auto Trait Implementations
impl Sync for Props
impl Send for Props
impl Unpin for Props
impl RefUnwindSafe for Props
impl UnwindSafe for Props
Blanket Implementations
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>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,