[−][src]Struct ico_memory::mem::IndexedDataStore
Methods
impl<'a, T> IndexedDataStore<'a, T>
[src]
pub const unsafe fn from_raw(
data: &'a *mut MaybeUninit<IndexedData<T>>,
capacity: u32
) -> IndexedDataStore<'a, T>
[src]
data: &'a *mut MaybeUninit<IndexedData<T>>,
capacity: u32
) -> IndexedDataStore<'a, T>
pub fn high_water_mark(&self) -> u32
[src]
How much of the buffer has ever been used.
pub fn active(&self) -> u32
[src]
How many objects are currently stored and accessible.
pub fn destroyed(&self) -> u32
[src]
How many objects are currently stored but marked destroyed.
pub fn available(&self) -> u32
[src]
How much free space. Capcity - (active + destroyed).
pub fn capacity(&self) -> u32
[src]
Total fixed capacity.
pub fn retain(&'a self, handle: IndexedHandle) -> Option<IndexedRef<T>>
[src]
Retain a strong reference. If no reference exists returns None, otherwise, this increments the reference count and returns the reference.
It is up to the user to manually release() the returned reference when they are finished.
pub fn get(&'a self, reference: &'a IndexedRef<T>) -> &'a T
[src]
pub fn clone(&'a self, reference: &'a IndexedRef<T>) -> IndexedRef<T>
[src]
pub fn release(&'a self, reference: IndexedRef<T>)
[src]
Release a strong reference. This decrements the reference count.
pub fn store(&self, value: T) -> IndexedHandle
[src]
pub fn free(&self, handle: IndexedHandle) -> bool
[src]
Trait Implementations
impl<'a, T> Drop for IndexedDataStore<'a, T>
[src]
Auto Trait Implementations
impl<'a, T> !Send for IndexedDataStore<'a, T>
impl<'a, T> Unpin for IndexedDataStore<'a, T>
impl<'a, T> !Sync for IndexedDataStore<'a, T>
impl<'a, T> !UnwindSafe for IndexedDataStore<'a, T>
impl<'a, T> !RefUnwindSafe for IndexedDataStore<'a, T>
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,