pub enum Ref {
Symbol(Symbol),
Content(ContentId),
Handle(HandleId),
Coord(Coordinate),
}Expand description
A stable reference to data or an object across the substrate.
The kernel defines the reference contract; libraries resolve a Ref to a
concrete value. A ref names its target by symbol, by content id, by a
process-local handle, or by a ranked coordinate.
Variants§
Symbol(Symbol)
A named reference resolved through the registry.
Content(ContentId)
A content-addressed reference to an immutable datum.
Handle(HandleId)
A process-local handle to a live object.
Coord(Coordinate)
A ranked coordinate within a named space.
Trait Implementations§
impl Eq for Ref
Source§impl Ord for Ref
impl Ord for Ref
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialOrd for Ref
impl PartialOrd for Ref
impl StructuralPartialEq for Ref
Auto Trait Implementations§
impl Freeze for Ref
impl RefUnwindSafe for Ref
impl Send for Ref
impl Sync for Ref
impl Unpin for Ref
impl UnsafeUnpin for Ref
impl UnwindSafe for Ref
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