Trait HeapAllocator
Source pub trait HeapAllocator {
// Required methods
fn allocate(&mut self, entry: HeapEntry) -> HeapHandleId;
fn deallocate(&mut self, handle: HeapHandleId) -> bool;
fn get(&self, handle: HeapHandleId) -> Option<&HeapEntry>;
fn get_mut(&mut self, handle: HeapHandleId) -> Option<&mut HeapEntry>;
fn get_entries(&self) -> &HashMap<HeapHandleId, HeapEntry>;
fn get_entries_mut(&mut self) -> &mut HashMap<HeapHandleId, HeapEntry>;
fn size(&self) -> usize;
fn is_empty(&self) -> bool;
fn clear(&mut self);
fn get_metrics(&self) -> &HeapMetrics;
}