Trait bevy_render::render_resource::encase::internal::BufferRef

source ·
pub trait BufferRef {
    // Required methods
    fn len(&self) -> usize;
    fn read<const N: usize>(&self, offset: usize) -> &[u8; N];
    fn read_slice(&self, offset: usize, val: &mut [u8]);
}

Required Methods§

source

fn len(&self) -> usize

source

fn read<const N: usize>(&self, offset: usize) -> &[u8; N]

source

fn read_slice(&self, offset: usize, val: &mut [u8])

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl BufferRef for Vec<u8>

source§

fn len(&self) -> usize

source§

fn read<const N: usize>(&self, offset: usize) -> &[u8; N]

source§

fn read_slice(&self, offset: usize, val: &mut [u8])

source§

impl BufferRef for [u8]

source§

fn len(&self) -> usize

source§

fn read<const N: usize>(&self, offset: usize) -> &[u8; N]

source§

fn read_slice(&self, offset: usize, val: &mut [u8])

source§

impl<T> BufferRef for &T
where T: BufferRef + ?Sized,

source§

fn len(&self) -> usize

source§

fn read<const N: usize>(&self, offset: usize) -> &[u8; N]

source§

fn read_slice(&self, offset: usize, val: &mut [u8])

source§

impl<T> BufferRef for &mut T
where T: BufferRef + ?Sized,

source§

fn len(&self) -> usize

source§

fn read<const N: usize>(&self, offset: usize) -> &[u8; N]

source§

fn read_slice(&self, offset: usize, val: &mut [u8])

source§

impl<T> BufferRef for Box<T>
where T: BufferRef + ?Sized,

source§

fn len(&self) -> usize

source§

fn read<const N: usize>(&self, offset: usize) -> &[u8; N]

source§

fn read_slice(&self, offset: usize, val: &mut [u8])

source§

impl<T> BufferRef for Rc<T>
where T: BufferRef + ?Sized,

source§

fn len(&self) -> usize

source§

fn read<const N: usize>(&self, offset: usize) -> &[u8; N]

source§

fn read_slice(&self, offset: usize, val: &mut [u8])

source§

impl<T> BufferRef for Arc<T>
where T: BufferRef + ?Sized,

source§

fn len(&self) -> usize

source§

fn read<const N: usize>(&self, offset: usize) -> &[u8; N]

source§

fn read_slice(&self, offset: usize, val: &mut [u8])

source§

impl<const LEN: usize> BufferRef for [u8; LEN]

source§

fn len(&self) -> usize

source§

fn read<const N: usize>(&self, offset: usize) -> &[u8; N]

source§

fn read_slice(&self, offset: usize, val: &mut [u8])

Implementors§