[−][src]Trait magnetic::buffer::Buffer
All buffers must implement this trait to be used with any of the queues.
Required methods
pub fn size(&self) -> usize
[src]
Return the size of the buffer
pub fn at(&self, idx: usize) -> *const T
[src]
Return a pointer to data at the given index. It is expected that this
function use modular arithmetic since idx
may refer to a location
beyond the end of the buffer.
pub fn at_mut(&mut self, idx: usize) -> *mut T
[src]
Return a mutable pointer to data at the given index. It is expected
that this function use modular arithmetic since idx
may refer to a
location beyond the end of the buffer.