pub struct UVecUninitTxBuffer { /* private fields */ }Expand description
Owned uninitialized buffer useful for tests and examples.
Implementations§
Source§impl UVecUninitTxBuffer
impl UVecUninitTxBuffer
Sourcepub fn new(metadata: UFrameMetadata, payload_len: usize) -> Self
pub fn new(metadata: UFrameMetadata, payload_len: usize) -> Self
Creates an owned uninitialized transmit buffer.
Sourcepub fn with_alignment(
metadata: UFrameMetadata,
payload_len: usize,
alignment: usize,
) -> Result<Self, UStatus>
pub fn with_alignment( metadata: UFrameMetadata, payload_len: usize, alignment: usize, ) -> Result<Self, UStatus>
Creates an owned uninitialized transmit buffer whose visible payload starts at alignment.
§Errors
Returns an error if the requested alignment is invalid or allocation size overflows.
Trait Implementations§
Source§impl Clone for UVecUninitTxBuffer
impl Clone for UVecUninitTxBuffer
Source§fn clone(&self) -> UVecUninitTxBuffer
fn clone(&self) -> UVecUninitTxBuffer
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 UVecUninitTxBuffer
impl Debug for UVecUninitTxBuffer
Source§impl UUninitTxBuffer for UVecUninitTxBuffer
impl UUninitTxBuffer for UVecUninitTxBuffer
Source§unsafe fn assume_payload_init(self) -> Self::Initialized
unsafe fn assume_payload_init(self) -> Self::Initialized
§Safety
Caller upholds the documented loan/witness contract for this handle: exclusive, layout-valid storage (constructors) or complete initialization of every transported byte (witness discharges).
Source§type Initialized = UVecTxBuffer
type Initialized = UVecTxBuffer
Initialized transmit loan type produced after payload initialization.
Source§fn metadata(&self) -> &UFrameMetadata
fn metadata(&self) -> &UFrameMetadata
Returns the immutable frame metadata associated with this transmit loan.
Source§fn payload_len(&self) -> usize
fn payload_len(&self) -> usize
Returns the visible application payload length.
Source§fn payload_uninit_mut(&mut self) -> &mut [MaybeUninit<u8>]
fn payload_uninit_mut(&mut self) -> &mut [MaybeUninit<u8>]
Returns mutable uninitialized application payload storage.
Auto Trait Implementations§
impl Freeze for UVecUninitTxBuffer
impl RefUnwindSafe for UVecUninitTxBuffer
impl Send for UVecUninitTxBuffer
impl Sync for UVecUninitTxBuffer
impl Unpin for UVecUninitTxBuffer
impl UnwindSafe for UVecUninitTxBuffer
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.