fidl_next::fuchsia::channel

Struct Buffer

Source
pub struct Buffer { /* private fields */ }
Expand description

A channel buffer.

Trait Implementations§

Source§

impl Encoder for Buffer

Source§

fn bytes_written(&self) -> usize

Returns the number of bytes written to the encoder.
Source§

fn reserve(&mut self, len: usize)

Writes zeroed bytes to the end of the encoder. Read more
Source§

fn write(&mut self, bytes: &[u8])

Copies bytes to the end of the encoder. Read more
Source§

fn rewrite(&mut self, pos: usize, bytes: &[u8])

Rewrites bytes at a position in the encoder.
Source§

impl HandleEncoder for Buffer

Source§

fn push_handle(&mut self, handle: Handle) -> Result<(), EncodeError>

Pushes a handle into the encoder.
Source§

fn handles_pushed(&self) -> usize

Returns the number of handles added to the encoder.

Auto 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> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<E> EncoderExt for E
where E: Encoder + ?Sized,

Source§

fn preallocate<T>(&mut self, len: usize) -> Preallocated<'_, E, T>

Pre-allocates space for a slice of elements.
Source§

fn encode_next_slice<T>(&mut self, values: &mut [T]) -> Result<(), EncodeError>
where T: Encode<E>,

Encodes a slice of elements. Read more
Source§

fn encode_next<T>(&mut self, value: &mut T) -> Result<(), EncodeError>
where T: Encode<E>,

Encodes a value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<T> Pointable for T

§

const ALIGN: usize = _

The alignment of pointer.
§

type Init = T

The type for initializers.
§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.