Struct wrpc_transport::AcceptedInvocation
source · pub struct AcceptedInvocation<Ctx, T, Tx: Transmitter> {
pub context: Ctx,
pub params: T,
pub result_subject: Tx::Subject,
pub error_subject: Tx::Subject,
pub transmitter: Tx,
}Expand description
An accepted invocation received from a peer
Fields§
§context: Ctx§params: T§result_subject: Tx::Subject§error_subject: Tx::Subject§transmitter: TxImplementations§
source§impl<Ctx, T, Tx: Transmitter> AcceptedInvocation<Ctx, T, Tx>
impl<Ctx, T, Tx: Transmitter> AcceptedInvocation<Ctx, T, Tx>
sourcepub fn map_context<U>(
self,
f: impl FnOnce(Ctx) -> U
) -> AcceptedInvocation<U, T, Tx>
pub fn map_context<U>( self, f: impl FnOnce(Ctx) -> U ) -> AcceptedInvocation<U, T, Tx>
Map [Self::context] to another type
sourcepub fn map_params<U>(
self,
f: impl FnOnce(T) -> U
) -> AcceptedInvocation<Ctx, U, Tx>
pub fn map_params<U>( self, f: impl FnOnce(T) -> U ) -> AcceptedInvocation<Ctx, U, Tx>
Map [Self::params] to another type
sourcepub fn map_transmitter<U: Transmitter>(
self,
f: impl FnOnce(Tx, Tx::Subject, Tx::Subject) -> (U, U::Subject, U::Subject)
) -> AcceptedInvocation<Ctx, T, U>
pub fn map_transmitter<U: Transmitter>( self, f: impl FnOnce(Tx, Tx::Subject, Tx::Subject) -> (U, U::Subject, U::Subject) ) -> AcceptedInvocation<Ctx, T, U>
Map [Self::transmitter], [Self::result_subject] and [Self::error_subject] to another type
Auto Trait Implementations§
impl<Ctx, T, Tx> Freeze for AcceptedInvocation<Ctx, T, Tx>
impl<Ctx, T, Tx> RefUnwindSafe for AcceptedInvocation<Ctx, T, Tx>where
Tx: Sync + RefUnwindSafe,
Ctx: RefUnwindSafe,
T: RefUnwindSafe,
<Tx as Transmitter>::Subject: RefUnwindSafe,
impl<Ctx, T, Tx> Send for AcceptedInvocation<Ctx, T, Tx>
impl<Ctx, T, Tx> Sync for AcceptedInvocation<Ctx, T, Tx>
impl<Ctx, T, Tx> Unpin for AcceptedInvocation<Ctx, T, Tx>
impl<Ctx, T, Tx> UnwindSafe for AcceptedInvocation<Ctx, T, Tx>where
Tx: Sync + UnwindSafe,
Ctx: UnwindSafe,
T: UnwindSafe,
<Tx as Transmitter>::Subject: UnwindSafe,
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