pub struct DecodablePayloads { /* private fields */ }Expand description
A codec-decoded set of payloads that can be deserialized later with to a user provided type.
Implementations§
Source§impl DecodablePayloads
impl DecodablePayloads
Sourcepub fn new(
payloads: Vec<Payload>,
payload_converter: PayloadConverter,
context: SerializationContextData,
) -> DecodablePayloads
pub fn new( payloads: Vec<Payload>, payload_converter: PayloadConverter, context: SerializationContextData, ) -> DecodablePayloads
Create a new decodable payload set from raw payloads and the converter context needed to deserialize them later.
Sourcepub fn deserialize<T>(&self) -> Result<T, PayloadConversionError>where
T: TemporalDeserializable + 'static,
pub fn deserialize<T>(&self) -> Result<T, PayloadConversionError>where
T: TemporalDeserializable + 'static,
Deserialize these payloads into a typed value using the stored payload converter.
Trait Implementations§
Source§impl Clone for DecodablePayloads
impl Clone for DecodablePayloads
Source§fn clone(&self) -> DecodablePayloads
fn clone(&self) -> DecodablePayloads
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for DecodablePayloads
impl Debug for DecodablePayloads
Source§impl From<DecodablePayloads> for FailurePayloads
impl From<DecodablePayloads> for FailurePayloads
Source§fn from(value: DecodablePayloads) -> FailurePayloads
fn from(value: DecodablePayloads) -> FailurePayloads
Converts to this type from the input type.
Auto Trait Implementations§
impl !RefUnwindSafe for DecodablePayloads
impl !UnwindSafe for DecodablePayloads
impl Freeze for DecodablePayloads
impl Send for DecodablePayloads
impl Sync for DecodablePayloads
impl Unpin for DecodablePayloads
impl UnsafeUnpin for DecodablePayloads
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request