Struct stateroom_server::ServiceActor
source · pub struct ServiceActor<J: StateroomService + Send + Sync + 'static> { /* private fields */ }Implementations§
source§impl<J: StateroomService + Send + Sync + 'static + Unpin> ServiceActor<J>
impl<J: StateroomService + Send + Sync + 'static + Unpin> ServiceActor<J>
pub fn new( ctx: &Context<Self>, service_factory: impl StateroomServiceFactory<ServiceActorContext, Service = J>, recipient: Recipient<MessageFromServer> ) -> Option<Self>
Trait Implementations§
source§impl<J: StateroomService + Send + Sync + 'static + Unpin> Actor for ServiceActor<J>
impl<J: StateroomService + Send + Sync + 'static + Unpin> Actor for ServiceActor<J>
§type Context = Context<ServiceActor<J>>
type Context = Context<ServiceActor<J>>
Actor execution context type
source§fn stopping(&mut self, _ctx: &mut Self::Context) -> Running
fn stopping(&mut self, _ctx: &mut Self::Context) -> Running
Called after an actor is in
Actor::Stopping state. Read moresource§fn started(&mut self, ctx: &mut Self::Context)
fn started(&mut self, ctx: &mut Self::Context)
Called when an actor gets polled the first time.
source§fn start(self) -> Addr<Self>where
Self: Actor<Context = Context<Self>>,
fn start(self) -> Addr<Self>where Self: Actor<Context = Context<Self>>,
Start a new asynchronous actor, returning its address. Read more