pub struct GraphOverlayDelta { /* private fields */ }Expand description
Staged, not-yet-durable graph edges and deletes for one traversal scope.
out_edges/in_edges mirror each other: Self::stage_edge inserts into
both so out- and in-neighbour lookups are each O(1) on the node string.
Implementations§
Source§impl GraphOverlayDelta
impl GraphOverlayDelta
Sourcepub fn stage_edge(&mut self, src: &str, label: &str, dst: &str)
pub fn stage_edge(&mut self, src: &str, label: &str, dst: &str)
Record a staged edge src -[label]-> dst, indexing it for both
out-neighbour (src) and in-neighbour (dst) lookups.
Sourcepub fn stage_tombstone(&mut self, src: &str, label: &str, dst: &str)
pub fn stage_tombstone(&mut self, src: &str, label: &str, dst: &str)
Record a staged deletion of src -[label]-> dst.
Sourcepub fn is_empty(&self) -> bool
pub fn is_empty(&self) -> bool
True when there is no staged state at all — the caller then takes the durable-only fast path.
Sourcepub fn out_neighbors<'a>(
&'a self,
src: &str,
label_filter: Option<&'a str>,
) -> impl Iterator<Item = (&'a str, &'a str)>
pub fn out_neighbors<'a>( &'a self, src: &str, label_filter: Option<&'a str>, ) -> impl Iterator<Item = (&'a str, &'a str)>
Staged out-neighbours of src as (label, dst), honouring
label_filter (when Some, only edges with that exact label).
Sourcepub fn in_neighbors<'a>(
&'a self,
dst: &str,
label_filter: Option<&'a str>,
) -> impl Iterator<Item = (&'a str, &'a str)>
pub fn in_neighbors<'a>( &'a self, dst: &str, label_filter: Option<&'a str>, ) -> impl Iterator<Item = (&'a str, &'a str)>
Staged in-neighbours of dst as (label, src), honouring
label_filter (when Some, only edges with that exact label).
Sourcepub fn staged_endpoint_names(&self) -> impl Iterator<Item = &str>
pub fn staged_endpoint_names(&self) -> impl Iterator<Item = &str>
Every node name that appears as an endpoint of a staged edge (as a
source in out_edges or a destination in in_edges).
A node created purely by an in-transaction edge write has no durable CSR id, so a pattern engine that enumerates free-ranging MATCH anchors from the CSR alone would never admit it. This lets such staged-only nodes be offered as candidate anchors. Names may repeat (a node that is both a staged source and a staged destination); callers dedup as needed.
Trait Implementations§
Source§impl Clone for GraphOverlayDelta
impl Clone for GraphOverlayDelta
Source§fn clone(&self) -> GraphOverlayDelta
fn clone(&self) -> GraphOverlayDelta
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for GraphOverlayDelta
impl Debug for GraphOverlayDelta
Source§impl Default for GraphOverlayDelta
impl Default for GraphOverlayDelta
Source§fn default() -> GraphOverlayDelta
fn default() -> GraphOverlayDelta
Auto Trait Implementations§
impl Freeze for GraphOverlayDelta
impl RefUnwindSafe for GraphOverlayDelta
impl Send for GraphOverlayDelta
impl Sync for GraphOverlayDelta
impl Unpin for GraphOverlayDelta
impl UnsafeUnpin for GraphOverlayDelta
impl UnwindSafe for GraphOverlayDelta
Blanket Implementations§
Source§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
Source§type ArchivedMetadata = ()
type ArchivedMetadata = ()
Source§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
Source§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Source§impl<T, N1, N2> Niching<NichedOption<T, N1>> for N2
impl<T, N1, N2> Niching<NichedOption<T, N1>> for N2
Source§unsafe fn is_niched(niched: *const NichedOption<T, N1>) -> bool
unsafe fn is_niched(niched: *const NichedOption<T, N1>) -> bool
Source§fn resolve_niched(out: Place<NichedOption<T, N1>>)
fn resolve_niched(out: Place<NichedOption<T, N1>>)
out indicating that a T is niched.impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.