Struct obj_pool::ParObjPool
source · [−]pub struct ParObjPool<T, const S: usize> { /* private fields */ }Implementations
sourceimpl<T, const S: usize> ParObjPool<T, S>
impl<T, const S: usize> ParObjPool<T, S>
pub fn new() -> Self
pub fn insert(&self, object: T) -> ObjId
pub fn remove(&self, obj_id: ObjId) -> Option<T>
pub fn get(&self, obj_id: ObjId) -> Option<MappedRwLockReadGuard<'_, T>>
pub fn get_mut(&self, obj_id: ObjId) -> Option<MappedRwLockWriteGuard<'_, T>>
pub fn clear(&self)
pub fn shrink_to_fit(&self)
pub fn capacity(&self) -> usize
Auto Trait Implementations
impl<T, const S: usize> !RefUnwindSafe for ParObjPool<T, S>
impl<T, const S: usize> Send for ParObjPool<T, S> where
T: Send,
impl<T, const S: usize> Sync for ParObjPool<T, S> where
T: Send + Sync,
impl<T, const S: usize> Unpin for ParObjPool<T, S> where
T: Unpin,
impl<T, const S: usize> UnwindSafe for ParObjPool<T, S> where
T: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more