pub struct RegistrationEnvelope {
pub event: RegistrationEvent,
pub update: bool,
pub promise: RegistrationPromise,
}Expand description
Envelope representing some registration event
Supported registration events are:
- Binding an actor reference to an actor path.
- Binding a routing policy to an named path.
Fields§
§event: RegistrationEventThe actual registration event
update: boolAllow existing registrations to be replaced by this registration
If false, attempting to register an existing path will result in an error.
promise: RegistrationPromiseAn optional feedback promise, which returns the newly registered actor path or an error
Implementations§
Source§impl RegistrationEnvelope
impl RegistrationEnvelope
Sourcepub fn actor(
actor: DynActorRef,
path: PathResolvable,
update: bool,
) -> RegistrationEnvelope
pub fn actor( actor: DynActorRef, path: PathResolvable, update: bool, ) -> RegistrationEnvelope
Create an actor registration envelope without a promise for feedback
Sourcepub fn actor_with_promise(
actor: DynActorRef,
path: PathResolvable,
update: bool,
promise: KPromise<Result<ActorPath, RegistrationError>>,
) -> RegistrationEnvelope
pub fn actor_with_promise( actor: DynActorRef, path: PathResolvable, update: bool, promise: KPromise<Result<ActorPath, RegistrationError>>, ) -> RegistrationEnvelope
Create an actor registration envelope using a promise for feedback
Sourcepub fn policy<P>(
policy: P,
path: Vec<String>,
update: bool,
) -> RegistrationEnvelopewhere
P: Into<StorePolicy>,
pub fn policy<P>(
policy: P,
path: Vec<String>,
update: bool,
) -> RegistrationEnvelopewhere
P: Into<StorePolicy>,
Create a policy registration envelope without a promise for feedback
Sourcepub fn policy_with_promise<P>(
policy: P,
path: Vec<String>,
update: bool,
promise: KPromise<Result<ActorPath, RegistrationError>>,
) -> RegistrationEnvelopewhere
P: Into<StorePolicy>,
pub fn policy_with_promise<P>(
policy: P,
path: Vec<String>,
update: bool,
promise: KPromise<Result<ActorPath, RegistrationError>>,
) -> RegistrationEnvelopewhere
P: Into<StorePolicy>,
Create a policy registration envelope without a promise for feedback
Trait Implementations§
Auto Trait Implementations§
impl Freeze for RegistrationEnvelope
impl !RefUnwindSafe for RegistrationEnvelope
impl Send for RegistrationEnvelope
impl Sync for RegistrationEnvelope
impl Unpin for RegistrationEnvelope
impl UnsafeUnpin for RegistrationEnvelope
impl !UnwindSafe for RegistrationEnvelope
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more