pub struct ObserveCreation<P: Protocol, Occurrence> {
pub creation: CreationId,
/* private fields */
}Expand description
Ask the local interpreter to return the committed result of the same-action creation ID through the behavior’s typed creation-result lane.
Equal address and message types do not make child protocols substitutable:
ⓘ
struct Store;
struct Gateway;
impl behavior::Protocol for Store {
type Addr = behavior::MailAddr;
type Msg = ();
}
impl behavior::Protocol for Gateway {
type Addr = behavior::MailAddr;
type Msg = ();
}
let creation = behavior::CreationSequence::new()
.issue()
.expect("the child creation ID exists");
let gateway = behavior_actors::ObserveCreation::<Gateway, behavior::ChildHead>::new(creation);
let _: behavior_actors::ObserveCreation<Store, behavior::ChildHead> = gateway;Fields§
§creation: CreationIdImplementations§
Source§impl<P: Protocol, Occurrence> ObserveCreation<P, Occurrence>
impl<P: Protocol, Occurrence> ObserveCreation<P, Occurrence>
pub const fn new(creation: CreationId) -> Self
Trait Implementations§
Source§impl<P, Occurrence> ActionItem for ObserveCreation<P, Occurrence>
impl<P, Occurrence> ActionItem for ObserveCreation<P, Occurrence>
type Custody = (Option<ObserveCreation<P, Occurrence>>, Option<<ObserveCreation<P, Occurrence> as ActionItem>::Reply>)
type Input<'a> = &'a mut Option<ObserveCreation<P, Occurrence>> where Self: 'a
type Reply = ItemSettlement<ObserveCreation<P, Occurrence>, <ObserveCreation<P, Occurrence> as ActionItem>::Accepted, <ObserveCreation<P, Occurrence> as ActionItem>::Rejection, <ObserveCreation<P, Occurrence> as ActionItem>::Prerequisite>
type Accepted = ()
type Rejection = Never
type Prerequisite = CreationCorrelation<P, Occurrence>
fn prepare_interpretation( progress: &mut Option<InterpretationProgress<Self, Self::Custody, Self::Reply>>, )
fn interpretation_input<'a>(
custody: &'a mut Self::Custody,
) -> Option<(Self::Input<'a>, &'a mut Option<Self::Reply>)>where
Self: 'a,
fn finish_interpretation( progress: &mut Option<InterpretationProgress<Self, Self::Custody, Self::Reply>>, )
Source§impl<P: Protocol, Occurrence> Clone for ObserveCreation<P, Occurrence>
impl<P: Protocol, Occurrence> Clone for ObserveCreation<P, Occurrence>
Source§impl<P: Protocol, Occurrence> Debug for ObserveCreation<P, Occurrence>
impl<P: Protocol, Occurrence> Debug for ObserveCreation<P, Occurrence>
Source§impl<P: Protocol, Occurrence> InterpreterRequest for ObserveCreation<P, Occurrence>
impl<P: Protocol, Occurrence> InterpreterRequest for ObserveCreation<P, Occurrence>
type ReturnToEmitter = ReturnsToEmitter<CreationResolved<<P as Protocol>::Addr>, Here>
type LogicalProtocols = NoBirthProtocols
Source§impl<P: Protocol, Occurrence> PartialEq for ObserveCreation<P, Occurrence>
impl<P: Protocol, Occurrence> PartialEq for ObserveCreation<P, Occurrence>
impl<P: Protocol, Occurrence> Copy for ObserveCreation<P, Occurrence>
impl<P: Protocol, Occurrence> Eq for ObserveCreation<P, Occurrence>
Auto Trait Implementations§
impl<P, Occurrence> Freeze for ObserveCreation<P, Occurrence>
impl<P, Occurrence> RefUnwindSafe for ObserveCreation<P, Occurrence>
impl<P, Occurrence> Send for ObserveCreation<P, Occurrence>
impl<P, Occurrence> Sync for ObserveCreation<P, Occurrence>
impl<P, Occurrence> Unpin for ObserveCreation<P, Occurrence>
impl<P, Occurrence> UnsafeUnpin for ObserveCreation<P, Occurrence>
impl<P, Occurrence> UnwindSafe for ObserveCreation<P, Occurrence>
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