pub struct StableContainerPayloadInfo {
pub type_name: String,
pub variant: StablePayloadVariant,
pub size: usize,
pub alignment: usize,
}Expand description
Type-agnostic stable-container metadata parsed from a payload encoding.
Fields§
§type_name: StringCross-process and cross-language stable type identity.
variant: StablePayloadVariantStable-container payload variant.
size: usizeExact payload size in bytes.
alignment: usizeAdvertised payload alignment in bytes.
Implementations§
Source§impl StableContainerPayloadInfo
impl StableContainerPayloadInfo
Sourcepub const ENCODING_ID: &'static str = STABLE_CONTAINER_ENCODING_ID
pub const ENCODING_ID: &'static str = STABLE_CONTAINER_ENCODING_ID
Native custom encoding id for stable-container payloads.
Sourcepub fn parse(encoding: &PayloadEncoding) -> Result<Self, UWireError>
pub fn parse(encoding: &PayloadEncoding) -> Result<Self, UWireError>
Parses stable-container metadata from a payload encoding.
§Errors
Returns an error if the encoding is not stable-container metadata or if the stable-container content type is malformed.
Sourcepub fn is_compatible_with<T>(&self) -> boolwhere
T: StablePayload,
pub fn is_compatible_with<T>(&self) -> boolwhere
T: StablePayload,
Returns whether this metadata is compatible with local stable payload T.
Trait Implementations§
Source§impl Clone for StableContainerPayloadInfo
impl Clone for StableContainerPayloadInfo
Source§fn clone(&self) -> StableContainerPayloadInfo
fn clone(&self) -> StableContainerPayloadInfo
Returns a copy of the value. Read more
1.0.0 · 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 StableContainerPayloadInfo
impl Debug for StableContainerPayloadInfo
impl Eq for StableContainerPayloadInfo
impl StructuralPartialEq for StableContainerPayloadInfo
Auto Trait Implementations§
impl Freeze for StableContainerPayloadInfo
impl RefUnwindSafe for StableContainerPayloadInfo
impl Send for StableContainerPayloadInfo
impl Sync for StableContainerPayloadInfo
impl Unpin for StableContainerPayloadInfo
impl UnwindSafe for StableContainerPayloadInfo
Blanket Implementations§
§impl<T> AnySync for T
impl<T> AnySync for T
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,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<TCore> UWithNativePrefixWire for TCore
impl<TCore> UWithNativePrefixWire for TCore
Source§fn into_native_prefix_wire_transport<W>(
self,
wire: W,
) -> UWireTransport<TCore, W, NativePrefixFrameMetadataCodec>where
W: UWire,
fn into_native_prefix_wire_transport<W>(
self,
wire: W,
) -> UWireTransport<TCore, W, NativePrefixFrameMetadataCodec>where
W: UWire,
Wraps this core with an external or custom selected wire using canonical metadata.
Source§fn into_protobuf_transport(
self,
) -> UWireTransport<TCore, ProtobufWire, NativePrefixFrameMetadataCodec>
fn into_protobuf_transport( self, ) -> UWireTransport<TCore, ProtobufWire, NativePrefixFrameMetadataCodec>
Wraps this core with the Protocol Buffers selected-wire profile.
Source§fn into_stable_container_transport(
self,
) -> UWireTransport<TCore, StableContainerWireFormat, NativePrefixFrameMetadataCodec>
fn into_stable_container_transport( self, ) -> UWireTransport<TCore, StableContainerWireFormat, NativePrefixFrameMetadataCodec>
Wraps this core with the stable-container selected-wire profile.