pub struct Buffer {
pub vmo: Handle,
pub size: u64,
}
Expand description
A buffer for data whose size is not necessarily a multiple of the page size.
DEPRECATED: This type is superfluous and deprecated. Instead of using this type, use a zx.Handle:VMO object and store the size of the contents in the ZX_PROP_VMO_CONTENT_SIZE property.
Fields§
§vmo: Handle
§size: u64
Trait Implementations§
Source§impl Encodable for Buffer
impl Encodable for Buffer
Source§type Encoded = WireBuffer
type Encoded = WireBuffer
The wire type for the value.
§const COPY_OPTIMIZATION: CopyOptimization<Self> = _
const COPY_OPTIMIZATION: CopyOptimization<Self> = _
An optimization flag that allows the bytes of this type to be copied directly during
encoding instead of calling
encode
. Read moreSource§impl EncodableOption for Box<Buffer>
impl EncodableOption for Box<Buffer>
Source§type EncodedOption = WireBox<WireBuffer>
type EncodedOption = WireBox<WireBuffer>
The wire type for the optional value.
Source§impl<___E> Encode<___E> for Bufferwhere
___E: InternalHandleEncoder + ?Sized + HandleEncoder,
impl<___E> Encode<___E> for Bufferwhere
___E: InternalHandleEncoder + ?Sized + HandleEncoder,
Source§impl<___E> EncodeOption<___E> for Box<Buffer>
impl<___E> EncodeOption<___E> for Box<Buffer>
Source§fn encode_option(
this: Option<&mut Self>,
encoder: &mut ___E,
out: &mut MaybeUninit<Self::EncodedOption>,
) -> Result<(), EncodeError>
fn encode_option( this: Option<&mut Self>, encoder: &mut ___E, out: &mut MaybeUninit<Self::EncodedOption>, ) -> Result<(), EncodeError>
Encodes this optional value into an encoder and output.
Source§impl TakeFrom<WireBuffer> for Buffer
impl TakeFrom<WireBuffer> for Buffer
Source§fn take_from(from: &WireBuffer) -> Self
fn take_from(from: &WireBuffer) -> Self
Converts from the given
T
, taking any resources that can’t be cloned.§const COPY_OPTIMIZATION: CopyOptimization<Self> = _
const COPY_OPTIMIZATION: CopyOptimization<Self> = _
An optimization flag that allows the bytes of this type to be copied directly during
conversion instead of calling
take_from
. Read moreAuto Trait Implementations§
impl Freeze for Buffer
impl RefUnwindSafe for Buffer
impl Send for Buffer
impl Sync for Buffer
impl Unpin for Buffer
impl UnwindSafe for Buffer
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