pub struct EdgeAllocator { /* private fields */ }Expand description
Monotonic, per-object allocation of stable edge identities.
Removing an edge is deliberately not an allocator operation: allocated
identities are evidence and remain consumed for the lifetime of their
owner. Once the u32 identity space is exhausted, every later allocation
fails without changing allocator state.
Implementations§
Source§impl EdgeAllocator
impl EdgeAllocator
Sourcepub fn allocate(
&mut self,
kind: EdgeKind,
) -> Result<TypedEdgeId, EdgeAllocationError>
pub fn allocate( &mut self, kind: EdgeKind, ) -> Result<TypedEdgeId, EdgeAllocationError>
Allocates the next identity with immutable kind semantics.
Trait Implementations§
Source§impl Clone for EdgeAllocator
impl Clone for EdgeAllocator
Source§fn clone(&self) -> EdgeAllocator
fn clone(&self) -> EdgeAllocator
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for EdgeAllocator
impl Debug for EdgeAllocator
Source§impl Default for EdgeAllocator
impl Default for EdgeAllocator
impl Eq for EdgeAllocator
Source§impl PartialEq for EdgeAllocator
impl PartialEq for EdgeAllocator
impl StructuralPartialEq for EdgeAllocator
Auto Trait Implementations§
impl Freeze for EdgeAllocator
impl RefUnwindSafe for EdgeAllocator
impl Send for EdgeAllocator
impl Sync for EdgeAllocator
impl Unpin for EdgeAllocator
impl UnsafeUnpin for EdgeAllocator
impl UnwindSafe for EdgeAllocator
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