pub struct MemoryPoolManager<F: Float> { /* private fields */ }Expand description
Memory pool manager
Implementations§
Source§impl<F: Float> MemoryPoolManager<F>
impl<F: Float> MemoryPoolManager<F>
Sourcepub fn get_buffer(&mut self, size: usize) -> Vec<F>
pub fn get_buffer(&mut self, size: usize) -> Vec<F>
Get a buffer from the pool
Sourcepub fn return_buffer(&mut self, buffer: Vec<F>)
pub fn return_buffer(&mut self, buffer: Vec<F>)
Return a buffer to the pool
Sourcepub fn get_stats(&self) -> &MemoryPoolStats
pub fn get_stats(&self) -> &MemoryPoolStats
Get pool statistics
Trait Implementations§
Auto Trait Implementations§
impl<F> Freeze for MemoryPoolManager<F>
impl<F> RefUnwindSafe for MemoryPoolManager<F>where
F: RefUnwindSafe,
impl<F> Send for MemoryPoolManager<F>
impl<F> Sync for MemoryPoolManager<F>
impl<F> Unpin for MemoryPoolManager<F>where
F: Unpin,
impl<F> UnsafeUnpin for MemoryPoolManager<F>
impl<F> UnwindSafe for MemoryPoolManager<F>where
F: UnwindSafe,
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more