pub struct SharedGraph { /* private fields */ }Expand description
Per-graph shared runtime state.
Since v1.2 (BRIEF 1) every snapshot publish is funneled through a single
per-graph committer thread (CommitterThread), which is
the sole writer of the snapshot ArcSwap cell. begin_write hands
each WriteTxn a cheap submit handle; commit/compact seal-and-submit
to the committer and block until it publishes. This single-committer +
sole-publisher discipline is what preserves D10 strict-serializability once
seal() drops the write lock early — it is load-bearing and NOT
type-enforced (a second committer or ArcSwap writer would silently break it).
Implementations§
Sourcepub fn vector_candidate_set(
&self,
name: &DbString,
) -> Result<Option<VectorCandidateSet>, ProviderError>
pub fn vector_candidate_set( &self, name: &DbString, ) -> Result<Option<VectorCandidateSet>, ProviderError>
Look up a generation-checked maintained vector candidate set by name.
Ok(None) means no maintained candidate-state provider is registered or
the provider has no set named name. The returned set is tied to the
same immutable snapshot generation used for the lookup.
§Errors
Returns ProviderError when the candidate-state provider is present
but cannot prove it has applied through the current graph generation.
Sourcepub fn vector_candidate_state_infos(
&self,
) -> Result<Vec<VectorCandidateStateInfo>, ProviderError>
pub fn vector_candidate_state_infos( &self, ) -> Result<Vec<VectorCandidateStateInfo>, ProviderError>
Return generation-checked metadata for maintained vector candidate states.
An empty vector means no maintained candidate-state provider is registered for this graph. The metadata is tied to the same immutable graph snapshot that supplies the generation value, so callers can use the returned names immediately with vector candidate-state scoring.
§Errors
Returns ProviderError when the candidate-state provider is present
but cannot prove it has applied through the current graph generation.
Sourcepub fn exact_json_contains_nodes(
&self,
label: &DbString,
property: &DbString,
candidate: &JsonValue,
k: usize,
) -> GraphResult<Vec<JsonContainmentHit>>
pub fn exact_json_contains_nodes( &self, label: &DbString, property: &DbString, candidate: &JsonValue, k: usize, ) -> GraphResult<Vec<JsonContainmentHit>>
Exhaustively find JSON-valued node properties in the current snapshot.
Sourcepub fn exact_json_contains_nodes_checked(
&self,
label: &DbString,
property: &DbString,
candidate: &JsonValue,
k: usize,
checker: CancellationChecker<'_>,
) -> Result<Vec<JsonContainmentHit>, JsonSearchError>
pub fn exact_json_contains_nodes_checked( &self, label: &DbString, property: &DbString, candidate: &JsonValue, k: usize, checker: CancellationChecker<'_>, ) -> Result<Vec<JsonContainmentHit>, JsonSearchError>
Exhaustively find JSON-valued node properties with cancellation checks.
Sourcepub fn exact_json_path_exists_nodes(
&self,
label: &DbString,
property: &DbString,
path: &[JsonPathSelector],
k: usize,
) -> GraphResult<Vec<JsonPathHit>>
pub fn exact_json_path_exists_nodes( &self, label: &DbString, property: &DbString, path: &[JsonPathSelector], k: usize, ) -> GraphResult<Vec<JsonPathHit>>
Exhaustively find JSON-valued node properties where path exists.
Sourcepub fn exact_json_path_exists_nodes_checked(
&self,
label: &DbString,
property: &DbString,
path: &[JsonPathSelector],
k: usize,
checker: CancellationChecker<'_>,
) -> Result<Vec<JsonPathHit>, JsonSearchError>
pub fn exact_json_path_exists_nodes_checked( &self, label: &DbString, property: &DbString, path: &[JsonPathSelector], k: usize, checker: CancellationChecker<'_>, ) -> Result<Vec<JsonPathHit>, JsonSearchError>
Exhaustively find JSON-valued node properties with path-existence checks.
Sourcepub fn exact_json_path_contains_nodes(
&self,
label: &DbString,
property: &DbString,
path: &[JsonPathSelector],
candidate: &JsonValue,
k: usize,
) -> GraphResult<Vec<JsonPathContainmentHit>>
pub fn exact_json_path_contains_nodes( &self, label: &DbString, property: &DbString, path: &[JsonPathSelector], candidate: &JsonValue, k: usize, ) -> GraphResult<Vec<JsonPathContainmentHit>>
Exhaustively find JSON-valued node properties whose selected path
contains candidate.
Sourcepub fn exact_json_path_contains_nodes_checked(
&self,
label: &DbString,
property: &DbString,
path: &[JsonPathSelector],
candidate: &JsonValue,
k: usize,
checker: CancellationChecker<'_>,
) -> Result<Vec<JsonPathContainmentHit>, JsonSearchError>
pub fn exact_json_path_contains_nodes_checked( &self, label: &DbString, property: &DbString, path: &[JsonPathSelector], candidate: &JsonValue, k: usize, checker: CancellationChecker<'_>, ) -> Result<Vec<JsonPathContainmentHit>, JsonSearchError>
Exhaustively find JSON path containment matches with cancellation checks.
Sourcepub fn exact_json_path_value_nodes(
&self,
label: &DbString,
property: &DbString,
path: &[JsonPathSelector],
k: usize,
) -> GraphResult<Vec<JsonPathValueHit>>
pub fn exact_json_path_value_nodes( &self, label: &DbString, property: &DbString, path: &[JsonPathSelector], k: usize, ) -> GraphResult<Vec<JsonPathValueHit>>
Exhaustively find JSON-valued node properties where path selects a value.
Sourcepub fn exact_json_path_value_nodes_checked(
&self,
label: &DbString,
property: &DbString,
path: &[JsonPathSelector],
k: usize,
checker: CancellationChecker<'_>,
) -> Result<Vec<JsonPathValueHit>, JsonSearchError>
pub fn exact_json_path_value_nodes_checked( &self, label: &DbString, property: &DbString, path: &[JsonPathSelector], k: usize, checker: CancellationChecker<'_>, ) -> Result<Vec<JsonPathValueHit>, JsonSearchError>
Exhaustively find JSON path values with cancellation checks.
Sourcepub fn exact_json_contains_candidate_nodes(
&self,
label: &DbString,
property: &DbString,
candidate: &JsonValue,
candidates: &[NodeId],
k: usize,
) -> GraphResult<Vec<JsonContainmentHit>>
pub fn exact_json_contains_candidate_nodes( &self, label: &DbString, property: &DbString, candidate: &JsonValue, candidates: &[NodeId], k: usize, ) -> GraphResult<Vec<JsonContainmentHit>>
Find candidate nodes whose JSON property contains candidate.
Sourcepub fn exact_json_contains_candidate_nodes_checked(
&self,
label: &DbString,
property: &DbString,
candidate: &JsonValue,
candidates: &[NodeId],
k: usize,
checker: CancellationChecker<'_>,
) -> Result<Vec<JsonContainmentHit>, JsonSearchError>
pub fn exact_json_contains_candidate_nodes_checked( &self, label: &DbString, property: &DbString, candidate: &JsonValue, candidates: &[NodeId], k: usize, checker: CancellationChecker<'_>, ) -> Result<Vec<JsonContainmentHit>, JsonSearchError>
Find candidate JSON containment matches with cancellation checks.
Sourcepub fn exact_json_path_exists_candidate_nodes(
&self,
label: &DbString,
property: &DbString,
path: &[JsonPathSelector],
candidates: &[NodeId],
k: usize,
) -> GraphResult<Vec<JsonPathHit>>
pub fn exact_json_path_exists_candidate_nodes( &self, label: &DbString, property: &DbString, path: &[JsonPathSelector], candidates: &[NodeId], k: usize, ) -> GraphResult<Vec<JsonPathHit>>
Find candidate nodes whose JSON property has path.
Sourcepub fn exact_json_path_exists_candidate_nodes_checked(
&self,
label: &DbString,
property: &DbString,
path: &[JsonPathSelector],
candidates: &[NodeId],
k: usize,
checker: CancellationChecker<'_>,
) -> Result<Vec<JsonPathHit>, JsonSearchError>
pub fn exact_json_path_exists_candidate_nodes_checked( &self, label: &DbString, property: &DbString, path: &[JsonPathSelector], candidates: &[NodeId], k: usize, checker: CancellationChecker<'_>, ) -> Result<Vec<JsonPathHit>, JsonSearchError>
Find candidate JSON path-existence matches with cancellation checks.
Sourcepub fn exact_json_path_contains_candidate_nodes(
&self,
label: &DbString,
property: &DbString,
options: JsonPathContainmentCandidateOptions<'_>,
) -> GraphResult<Vec<JsonPathContainmentHit>>
pub fn exact_json_path_contains_candidate_nodes( &self, label: &DbString, property: &DbString, options: JsonPathContainmentCandidateOptions<'_>, ) -> GraphResult<Vec<JsonPathContainmentHit>>
Find candidate nodes whose selected JSON path contains candidate.
Sourcepub fn exact_json_path_contains_candidate_nodes_checked(
&self,
label: &DbString,
property: &DbString,
options: JsonPathContainmentCandidateOptions<'_>,
checker: CancellationChecker<'_>,
) -> Result<Vec<JsonPathContainmentHit>, JsonSearchError>
pub fn exact_json_path_contains_candidate_nodes_checked( &self, label: &DbString, property: &DbString, options: JsonPathContainmentCandidateOptions<'_>, checker: CancellationChecker<'_>, ) -> Result<Vec<JsonPathContainmentHit>, JsonSearchError>
Find candidate JSON path-containment matches with cancellation checks.
Sourcepub fn exact_json_path_value_candidate_nodes(
&self,
label: &DbString,
property: &DbString,
path: &[JsonPathSelector],
candidates: &[NodeId],
k: usize,
) -> GraphResult<Vec<JsonPathValueHit>>
pub fn exact_json_path_value_candidate_nodes( &self, label: &DbString, property: &DbString, path: &[JsonPathSelector], candidates: &[NodeId], k: usize, ) -> GraphResult<Vec<JsonPathValueHit>>
Return selected JSON values for matching candidate nodes.
Sourcepub fn exact_json_path_value_candidate_nodes_checked(
&self,
label: &DbString,
property: &DbString,
path: &[JsonPathSelector],
candidates: &[NodeId],
k: usize,
checker: CancellationChecker<'_>,
) -> Result<Vec<JsonPathValueHit>, JsonSearchError>
pub fn exact_json_path_value_candidate_nodes_checked( &self, label: &DbString, property: &DbString, path: &[JsonPathSelector], candidates: &[NodeId], k: usize, checker: CancellationChecker<'_>, ) -> Result<Vec<JsonPathValueHit>, JsonSearchError>
Return selected candidate JSON path values with cancellation checks.
Sourcepub fn recover(dir: &Path, graph_id: GraphId) -> GraphResult<Self>
pub fn recover(dir: &Path, graph_id: GraphId) -> GraphResult<Self>
Recover an open (GG01) shared graph from a persistence directory.
graph_id is the caller-asserted identity. If a snapshot is present
and declares a bound_type, recovery fails — a closed graph must be
recovered via SharedGraph::recover_closed.
§Errors
Returns persistence errors, crate::GraphError::Provider when a
snapshot disagrees with graph_id or declares a closed binding, or
graph errors when the recovered state cannot be materialized.
Sourcepub fn recover_with_providers(
dir: &Path,
graph_id: GraphId,
providers: Vec<Arc<dyn IndexProvider>>,
) -> GraphResult<Self>
pub fn recover_with_providers( dir: &Path, graph_id: GraphId, providers: Vec<Arc<dyn IndexProvider>>, ) -> GraphResult<Self>
Recover an open (GG01) shared graph with extension index providers.
Each supplied provider participates in snapshot-section recovery and WAL replay, then remains attached to the returned graph so future commits route to the same provider set.
§Errors
Returns persistence errors, crate::GraphError::Provider when provider
tags are duplicated or recovered provider state is inconsistent, or graph
errors when the recovered state cannot be materialized.
Sourcepub fn recover_closed(
dir: &Path,
graph_id: GraphId,
bound_type: GraphTypeDef,
) -> GraphResult<Self>
pub fn recover_closed( dir: &Path, graph_id: GraphId, bound_type: GraphTypeDef, ) -> GraphResult<Self>
Recover a closed (GG02) shared graph bound to bound_type.
graph_id and bound_type are caller-asserted; recovery validates
against the snapshot:
- If the snapshot’s
CORE/METAreferences abound_typeviaCORE/GTYP, it must equalbound_typeor recovery fails (drift). - If the snapshot declares no binding but
bound_typeis provided, recovery fails (snapshot says open, caller says closed). - If no snapshot is present (WAL-only or empty-dir), the caller’s
bound_typeis used and validation runs against replayed state.
§Errors
Returns persistence errors, crate::GraphError::Provider on type
drift / inconsistency, crate::GraphError::TypeViolation when
recovered entities don’t conform to bound_type, or graph errors
when the recovered state cannot be materialized.
Sourcepub fn recover_closed_with_providers(
dir: &Path,
graph_id: GraphId,
bound_type: GraphTypeDef,
providers: Vec<Arc<dyn IndexProvider>>,
) -> GraphResult<Self>
pub fn recover_closed_with_providers( dir: &Path, graph_id: GraphId, bound_type: GraphTypeDef, providers: Vec<Arc<dyn IndexProvider>>, ) -> GraphResult<Self>
Recover a closed (GG02) shared graph with extension index providers.
This is the provider-aware counterpart to SharedGraph::recover_closed.
Recovery validates the caller-supplied bound_type, rebuilds the supplied
index providers from snapshot sections and WAL replay, and returns a live
WAL-backed graph with those providers still attached.
§Errors
Returns persistence errors, crate::GraphError::Provider on provider
tag duplication or type drift,
crate::GraphError::TypeViolation when recovered entities don’t
conform to bound_type, or graph errors when the recovered state cannot
be materialized.
Sourcepub fn create_property_index(
&self,
label: DbString,
property: DbString,
kind: TypedIndexKind,
) -> GraphResult<()>
pub fn create_property_index( &self, label: DbString, property: DbString, kind: TypedIndexKind, ) -> GraphResult<()>
Register a built-in node property index for (label, property).
The current node columns are scanned under the write lock and the published snapshot is updated in one transaction.
§Errors
Returns GraphError::PropertyIndexAlreadyExists if the pair is
already registered, or GraphError::IndexValueRejected if any
existing node with label has a non-null value that does not match
kind.
Sourcepub fn create_property_index_named(
&self,
label: DbString,
property: DbString,
kind: TypedIndexKind,
name: Option<DbString>,
) -> GraphResult<()>
pub fn create_property_index_named( &self, label: DbString, property: DbString, kind: TypedIndexKind, name: Option<DbString>, ) -> GraphResult<()>
Register a built-in node property index with optional catalog name.
Sourcepub fn drop_property_index(
&self,
label: DbString,
property: DbString,
) -> GraphResult<()>
pub fn drop_property_index( &self, label: DbString, property: DbString, ) -> GraphResult<()>
Drop a built-in node property index.
The operation is idempotent; dropping an absent index succeeds without publishing a new snapshot.
Sourcepub fn create_edge_property_index(
&self,
label: DbString,
property: DbString,
kind: TypedIndexKind,
) -> GraphResult<()>
pub fn create_edge_property_index( &self, label: DbString, property: DbString, kind: TypedIndexKind, ) -> GraphResult<()>
Register a built-in edge property index for (label, property).
The current edge columns are scanned under the write lock and the published snapshot is updated in one transaction.
§Errors
Returns GraphError::PropertyIndexAlreadyExists if the pair is
already registered, or GraphError::IndexValueRejected if any
existing edge with label has a non-null value that does not match
kind.
Sourcepub fn create_edge_property_index_named(
&self,
label: DbString,
property: DbString,
kind: TypedIndexKind,
name: Option<DbString>,
) -> GraphResult<()>
pub fn create_edge_property_index_named( &self, label: DbString, property: DbString, kind: TypedIndexKind, name: Option<DbString>, ) -> GraphResult<()>
Register a built-in edge property index with optional catalog name.
Sourcepub fn drop_edge_property_index(
&self,
label: DbString,
property: DbString,
) -> GraphResult<()>
pub fn drop_edge_property_index( &self, label: DbString, property: DbString, ) -> GraphResult<()>
Drop a built-in edge property index.
The operation is idempotent; dropping an absent index succeeds without publishing a new snapshot.
Sourcepub fn create_vector_index(
&self,
label: DbString,
property: DbString,
kind: VectorIndexKind,
dimension: u32,
) -> GraphResult<()>
pub fn create_vector_index( &self, label: DbString, property: DbString, kind: VectorIndexKind, dimension: u32, ) -> GraphResult<()>
Register a built-in node vector index for (label, property).
The current node columns are scanned under the write lock and the published snapshot is updated in one transaction.
§Errors
Returns GraphError::VectorIndexAlreadyExists if the pair is already
registered, GraphError::VectorIndexInvalidDimension when dimension
is zero, or GraphError::VectorIndexValueRejected if any existing
node with label has a non-null value for property that is not a
vector with the declared dimension.
Sourcepub fn create_vector_index_named(
&self,
label: DbString,
property: DbString,
kind: VectorIndexKind,
dimension: u32,
name: Option<DbString>,
) -> GraphResult<()>
pub fn create_vector_index_named( &self, label: DbString, property: DbString, kind: VectorIndexKind, dimension: u32, name: Option<DbString>, ) -> GraphResult<()>
Register a built-in node vector index with optional catalog name.
Sourcepub fn create_vector_index_named_with_config(
&self,
label: DbString,
property: DbString,
kind: VectorIndexKind,
dimension: u32,
name: Option<DbString>,
hnsw_config: Option<HnswIndexConfig>,
) -> GraphResult<()>
pub fn create_vector_index_named_with_config( &self, label: DbString, property: DbString, kind: VectorIndexKind, dimension: u32, name: Option<DbString>, hnsw_config: Option<HnswIndexConfig>, ) -> GraphResult<()>
Register a built-in node vector index with optional HNSW construction config.
Sourcepub fn create_vector_index_named_with_configs(
&self,
label: DbString,
property: DbString,
kind: VectorIndexKind,
dimension: u32,
name: Option<DbString>,
config: VectorIndexConfig,
) -> GraphResult<()>
pub fn create_vector_index_named_with_configs( &self, label: DbString, property: DbString, kind: VectorIndexKind, dimension: u32, name: Option<DbString>, config: VectorIndexConfig, ) -> GraphResult<()>
Register a built-in node vector index with optional ANN construction config.
Sourcepub fn drop_vector_index(
&self,
label: DbString,
property: DbString,
) -> GraphResult<()>
pub fn drop_vector_index( &self, label: DbString, property: DbString, ) -> GraphResult<()>
Drop a built-in node vector index.
The operation is idempotent; dropping an absent index succeeds without publishing a new snapshot.
Sourcepub fn create_text_index(
&self,
label: DbString,
property: DbString,
) -> GraphResult<()>
pub fn create_text_index( &self, label: DbString, property: DbString, ) -> GraphResult<()>
Register a built-in node text index for (label, property).
The current node columns are scanned under the write lock and the published snapshot is updated in one transaction.
§Errors
Returns GraphError::TextIndexAlreadyExists if the pair is already
registered, or GraphError::Inconsistent if index construction
observes corrupt graph columns.
Sourcepub fn create_text_index_named(
&self,
label: DbString,
property: DbString,
name: Option<DbString>,
) -> GraphResult<()>
pub fn create_text_index_named( &self, label: DbString, property: DbString, name: Option<DbString>, ) -> GraphResult<()>
Register a built-in node text index with optional catalog name.
Sourcepub fn drop_text_index(
&self,
label: DbString,
property: DbString,
) -> GraphResult<()>
pub fn drop_text_index( &self, label: DbString, property: DbString, ) -> GraphResult<()>
Drop a built-in node text index.
The operation is idempotent; dropping an absent index succeeds without publishing a new snapshot.
Sourcepub fn builder(graph_id: GraphId) -> SharedGraphBuilder
pub fn builder(graph_id: GraphId) -> SharedGraphBuilder
Start building an empty shared graph with optional providers.
Sourcepub fn from_graph(graph: SeleneGraph) -> Self
pub fn from_graph(graph: SeleneGraph) -> Self
Construct shared state from a pre-built graph snapshot.
The allocator floors are derived from storage length so that stale
GraphMeta.next_*_id values cannot allow ID reuse over rows that
already exist (recovery hardening — spec 02 §4 forbids ID reuse).
§Panics
Panics if the supplied graph contains more than u32::MAX rows in
either store. Selene-graph’s row index is u32 by construction;
SeleneGraph::new() always satisfies this, and any caller-built
fixture must too. Use SharedGraph::try_from_graph for the
fallible variant when validating untrusted snapshots.
Sourcepub fn try_from_graph(graph: SeleneGraph) -> GraphResult<Self>
pub fn try_from_graph(graph: SeleneGraph) -> GraphResult<Self>
Fallible variant of SharedGraph::from_graph. Returns
GraphError::Inconsistent when the graph’s stores exceed the
u32 row capacity.
Sourcepub fn from_graph_with_providers(
graph: SeleneGraph,
providers: Vec<Arc<dyn IndexProvider>>,
) -> GraphResult<Self>
pub fn from_graph_with_providers( graph: SeleneGraph, providers: Vec<Arc<dyn IndexProvider>>, ) -> GraphResult<Self>
Construct shared state from a graph snapshot and fixed provider list.
§Errors
Returns GraphError::Provider when two providers declare the same
ProviderTag, and GraphError::Inconsistent when the graph’s
stores exceed the u32 row capacity.
Sourcepub fn from_graph_with_wal(
graph: SeleneGraph,
path: impl AsRef<Path>,
config: WalConfig,
) -> GraphResult<Self>
pub fn from_graph_with_wal( graph: SeleneGraph, path: impl AsRef<Path>, config: WalConfig, ) -> GraphResult<Self>
Construct shared state from a graph snapshot and commit-critical WAL file.
Since v1.2 (BRIEF 2) the committer is the sole fsync caller, so the WAL is
always opened in SyncPolicy::OnFlushOnly regardless of the
config.sync_policy passed (it is overwritten before
WalWriter::open). This non-builder constructor uses
CommitBatching::Off, so the committer still fsyncs once per commit —
behaviorally identical to BRIEF 1’s EveryN(1).
§Errors
Returns GraphError::Persist when the WAL cannot be opened, plus the
same consistency and provider-registration errors as Self::try_from_graph.
Sourcepub fn read(&self) -> Arc<SeleneGraph>
pub fn read(&self) -> Arc<SeleneGraph>
Load the current immutable snapshot without taking the write lock.
Sourcepub fn compaction_stats(&self) -> CompactionStats
pub fn compaction_stats(&self) -> CompactionStats
Return compaction pressure for the current published snapshot.
This is a lock-free read of row counts and liveness counters. It does not compact, rebuild indexes, or take the writer lock.
Sourcepub fn compact(&self) -> GraphResult<CompactionReport>
pub fn compact(&self) -> GraphResult<CompactionReport>
Compact the live graph in place: reclaim every dead / hole row, renumber rows dense, and atomically republish the result so the RAM held by deleted rows is reclaimed immediately (BRIEF-Item-4c — the live-densify half of snapshot-time compaction).
This is pure space reclamation: it changes only the internal row layout,
never external NodeId/EdgeId, properties, or labels, so it emits no
selene_core::Change and writes no WAL entry. Durability
comes from the next snapshot, which encodes the now-dense live graph (the
CORE provider reads the same snapshot cell this method publishes into). A
crash before that snapshot simply reloads the pre-compaction state and
recompacts later — compaction can never lose data.
The dense graph is built under the write lock on the calling thread
(seal-and-handover, exactly like a commit), and is allocated a publish
seal_seq under that same lock; the single committer then swaps it into
the published snapshot cell strictly in seal_seq order. So compaction
serializes with writers exactly like a commit and can never be reordered
ahead of an earlier-sealed commit (which would let that commit’s stale,
non-dense frozen snapshot clobber the dense one). Lock-free readers keep
observing the old snapshot until the dense graph is published. The
monotonic allocator high-water marks are preserved (the live allocator is
untouched, and compact_core carries GraphMeta
verbatim — and the allocator is kept in sync with GraphMeta on every
commit), so no external id is ever reused after a later recovery.
§Errors
Returns GraphError if the graph’s id↔row mapping is corrupt or the
recompacted graph fails its consistency check (see
compact_core).
Sourcepub fn rebuild_vector_indexes(&self) -> GraphResult<VectorIndexRebuildReport>
pub fn rebuild_vector_indexes(&self) -> GraphResult<VectorIndexRebuildReport>
Rebuild every registered vector index from primary node values.
HNSW indexes retain stale deleted entries after vector update/delete so
in-flight search can still traverse the neighbor graph safely. This
maintenance path reclaims those stale entries by rebuilding only the
derived vector-index state; it does not change graph data, emit
selene_core::Change, write a WAL entry, bump schema epoch, or
notify providers. The HNSW graph is derived, not durable: snapshots and
recovery persist only vector-index registrations plus primary values, so
a reopen rebuilds the index from that authoritative state.
The rebuild is strict on live data: if an indexed row no longer satisfies the registered vector dimension/metric invariant, this method returns an error instead of silently dropping the row from the index.
Sourcepub fn rebuild_recommended_vector_indexes(
&self,
) -> GraphResult<VectorIndexRebuildReport>
pub fn rebuild_recommended_vector_indexes( &self, ) -> GraphResult<VectorIndexRebuildReport>
Rebuild only vector indexes whose diagnostics recommend maintenance.
This is the bounded maintenance variant for IVF drift: it uses each index’s current
ivf_rebuild_recommended
value to decide whether to rebuild that derived index. Indexes that do not recommend rebuild
are left untouched, and a no-op call returns an empty report without publishing a maintenance
item.
The rebuild is strict on live data for selected indexes, matching
Self::rebuild_vector_indexes.
Sourcepub fn maintain_vector_indexes(
&self,
policy: VectorIndexMaintenancePolicy,
) -> GraphResult<VectorIndexRebuildReport>
pub fn maintain_vector_indexes( &self, policy: VectorIndexMaintenancePolicy, ) -> GraphResult<VectorIndexRebuildReport>
Maintain recommended vector indexes under a caller-supplied policy.
This is the explicit orchestration API for amortized vector-index maintenance. It rebuilds only indexes whose diagnostics currently recommend maintenance and applies the policy cap after ordering recommended indexes by pending IVF retrain pressure. It remains a maintenance-tier operation: reads never trigger it, and a no-op call returns an empty report without publishing a derived-state replacement.
The rebuild is strict on live data for selected indexes, matching
Self::rebuild_vector_indexes.
Sourcepub fn schema_version(&self) -> u64
pub fn schema_version(&self) -> u64
Return the runtime schema-version epoch used for plan-cache invalidation.
The epoch starts at zero for each SharedGraph instance and advances
only after a successful commit whose change set contains
selene_core::Change::SchemaChanged.
Sourcepub fn graph_type(&self) -> Option<Arc<GraphTypeDef>>
pub fn graph_type(&self) -> Option<Arc<GraphTypeDef>>
Return the bound graph type, if this is a closed graph.
Sourcepub fn index_provider_by_tag(
&self,
tag: ProviderTag,
) -> Option<Arc<dyn IndexProvider>>
pub fn index_provider_by_tag( &self, tag: ProviderTag, ) -> Option<Arc<dyn IndexProvider>>
Look up a registered provider by tag.
Sourcepub fn index_providers(&self) -> &[Arc<dyn IndexProvider>]
pub fn index_providers(&self) -> &[Arc<dyn IndexProvider>]
Borrow the fixed provider registry for executor procedure contexts.
Sourcepub fn durable_providers(&self) -> &[Arc<dyn DurableProvider>]
pub fn durable_providers(&self) -> &[Arc<dyn DurableProvider>]
Borrow the fixed commit-critical durable provider registry.
Sourcepub fn begin_write(&self) -> WriteTxn<'_>
pub fn begin_write(&self) -> WriteTxn<'_>
Begin a write transaction by acquiring the single graph write lock.
Concurrent writers from other threads queue normally on the write lock; the engine does not panic legitimate concurrent writes during another commit’s provider fanout.
Since v1.2 (BRIEF 1) the actual snapshot publish happens on the single
committer thread, not here: WriteTxn::commit seals under this lock,
releases it, and hands the frozen bundle to the committer. Provider
fan-out therefore now runs on the committer thread, so the
re-entrancy guard below protects the committer thread (sound with exactly
one committer — see reentry.rs and the v1.2 design §7.7).
§Panics
Panics when called from inside an IndexProvider callback on
the committer thread as the active fanout. Re-entrant writes from a
provider callback are unsupported; the committer is publishing, so a
nested write would recurse indefinitely. The panic is caught by the
committer’s notify_providers boundary; provider state may drift, but
the commit still completes.
Cross-thread re-entry — a provider spawning a worker thread that
calls begin_write and waiting for it — is documented misuse
rather than a detectable footgun (the engine cannot trace causal
thread ancestry). See the module docs in reentry.rs and the
IndexProvider rustdoc for the contract.
Sourcepub fn write_snapshot(
&self,
config: SnapshotConfig,
) -> GraphResult<SnapshotFinalizeOutcome>
pub fn write_snapshot( &self, config: SnapshotConfig, ) -> GraphResult<SnapshotFinalizeOutcome>
Write one snapshot containing every registered provider section.
This is the graph-layer facade over SnapshotBuilder. It walks the
fixed provider registry, asks each provider to encode every declared
subsection, and finalizes the snapshot envelope from config.
Call after the commit whose state should be checkpointed has returned. Callers that need a deterministic checkpoint should avoid concurrent writes while this method is collecting provider sections.
§Errors
Returns crate::GraphError::Provider when a provider cannot encode one
of its declared sections, or crate::GraphError::Persist when the
snapshot envelope cannot be finalized.
Sourcepub fn build_text_index(
&self,
label: &DbString,
property: &DbString,
) -> GraphResult<TextIndex>
pub fn build_text_index( &self, label: &DbString, property: &DbString, ) -> GraphResult<TextIndex>
Build a reusable BM25 postings index from the current shared snapshot.
§Errors
Returns GraphError::Inconsistent if index construction observes corrupt
graph columns.
Sourcepub fn indexed_text_search_nodes(
&self,
label: &DbString,
property: &DbString,
query: &str,
k: usize,
) -> GraphResult<Vec<TextSearchHit>>
pub fn indexed_text_search_nodes( &self, label: &DbString, property: &DbString, query: &str, k: usize, ) -> GraphResult<Vec<TextSearchHit>>
Rank string-valued node properties through a transient postings index.
§Errors
Returns GraphError::Inconsistent if index construction observes corrupt
graph columns.
Sourcepub fn exact_text_search_nodes(
&self,
label: &DbString,
property: &DbString,
query: &str,
k: usize,
) -> GraphResult<Vec<TextSearchHit>>
pub fn exact_text_search_nodes( &self, label: &DbString, property: &DbString, query: &str, k: usize, ) -> GraphResult<Vec<TextSearchHit>>
Exhaustively rank string-valued node properties in the current snapshot.
Sourcepub fn exact_text_search_nodes_checked(
&self,
label: &DbString,
property: &DbString,
query: &str,
k: usize,
checker: CancellationChecker<'_>,
) -> Result<Vec<TextSearchHit>, TextSearchError>
pub fn exact_text_search_nodes_checked( &self, label: &DbString, property: &DbString, query: &str, k: usize, checker: CancellationChecker<'_>, ) -> Result<Vec<TextSearchHit>, TextSearchError>
Exhaustively rank string-valued node properties with cancellation checks.
Sourcepub fn exact_vector_search_nodes(
&self,
label: &DbString,
property: &DbString,
query: &VectorValue,
metric: VectorMetric,
k: usize,
) -> GraphResult<Vec<VectorNodeSearchHit>>
pub fn exact_vector_search_nodes( &self, label: &DbString, property: &DbString, query: &VectorValue, metric: VectorMetric, k: usize, ) -> GraphResult<Vec<VectorNodeSearchHit>>
Exhaustively rank vector-valued node properties in the current snapshot.
This loads one immutable snapshot and delegates to
crate::SeleneGraph::exact_vector_search_nodes, so the result is
lock-free with respect to concurrent writers once the snapshot pointer is
read.
Sourcepub fn exact_vector_search_nodes_checked(
&self,
label: &DbString,
property: &DbString,
query: &VectorValue,
metric: VectorMetric,
k: usize,
checker: CancellationChecker<'_>,
) -> Result<Vec<VectorNodeSearchHit>, VectorSearchError>
pub fn exact_vector_search_nodes_checked( &self, label: &DbString, property: &DbString, query: &VectorValue, metric: VectorMetric, k: usize, checker: CancellationChecker<'_>, ) -> Result<Vec<VectorNodeSearchHit>, VectorSearchError>
Exhaustively rank vector-valued node properties with cancellation checks.
This loads one immutable snapshot and delegates to
crate::SeleneGraph::exact_vector_search_nodes_checked.
Sourcepub fn exact_vector_search_nodes_batch_checked(
&self,
label: &DbString,
property: &DbString,
queries: &[VectorValue],
metric: VectorMetric,
k: usize,
checker: CancellationChecker<'_>,
) -> Result<Vec<Vec<VectorNodeSearchHit>>, VectorSearchError>
pub fn exact_vector_search_nodes_batch_checked( &self, label: &DbString, property: &DbString, queries: &[VectorValue], metric: VectorMetric, k: usize, checker: CancellationChecker<'_>, ) -> Result<Vec<Vec<VectorNodeSearchHit>>, VectorSearchError>
Lock-free read snapshot wrapper for exact vector batch search.
Sourcepub fn approximate_vector_search_nodes_checked(
&self,
label: &DbString,
property: &DbString,
query: &VectorValue,
options: ApproximateVectorSearchOptions,
checker: CancellationChecker<'_>,
) -> Result<Vec<VectorNodeSearchHit>, VectorSearchError>
pub fn approximate_vector_search_nodes_checked( &self, label: &DbString, property: &DbString, query: &VectorValue, options: ApproximateVectorSearchOptions, checker: CancellationChecker<'_>, ) -> Result<Vec<VectorNodeSearchHit>, VectorSearchError>
Approximately rank vector-valued node properties through an ANN index.
This loads one immutable snapshot and delegates to
crate::SeleneGraph::approximate_vector_search_nodes_checked.
Sourcepub fn approximate_vector_search_nodes_batch_checked(
&self,
label: &DbString,
property: &DbString,
queries: &[VectorValue],
options: ApproximateVectorSearchOptions,
checker: CancellationChecker<'_>,
) -> Result<Vec<Vec<VectorNodeSearchHit>>, VectorSearchError>
pub fn approximate_vector_search_nodes_batch_checked( &self, label: &DbString, property: &DbString, queries: &[VectorValue], options: ApproximateVectorSearchOptions, checker: CancellationChecker<'_>, ) -> Result<Vec<Vec<VectorNodeSearchHit>>, VectorSearchError>
Lock-free read snapshot wrapper for approximate vector batch search.
Sourcepub fn approximate_vector_search_candidate_set_checked(
&self,
label: &DbString,
property: &DbString,
query: &VectorValue,
candidates: &VectorCandidateSet,
options: ApproximateVectorSearchOptions,
checker: CancellationChecker<'_>,
) -> Result<Vec<VectorNodeSearchHit>, VectorSearchError>
pub fn approximate_vector_search_candidate_set_checked( &self, label: &DbString, property: &DbString, query: &VectorValue, candidates: &VectorCandidateSet, options: ApproximateVectorSearchOptions, checker: CancellationChecker<'_>, ) -> Result<Vec<VectorNodeSearchHit>, VectorSearchError>
Lock-free read snapshot wrapper for approximate search within candidates.
Sourcepub fn approximate_vector_search_candidate_sets_batch_checked(
&self,
label: &DbString,
property: &DbString,
queries: &[VectorValue],
candidate_sets: &[VectorCandidateSet],
options: ApproximateVectorSearchOptions,
checker: CancellationChecker<'_>,
) -> Result<Vec<Vec<VectorNodeSearchHit>>, VectorSearchError>
pub fn approximate_vector_search_candidate_sets_batch_checked( &self, label: &DbString, property: &DbString, queries: &[VectorValue], candidate_sets: &[VectorCandidateSet], options: ApproximateVectorSearchOptions, checker: CancellationChecker<'_>, ) -> Result<Vec<Vec<VectorNodeSearchHit>>, VectorSearchError>
Lock-free read snapshot wrapper for approximate batch search within candidates.
Sourcepub fn approximate_vector_search_expanded_candidates_checked(
&self,
label: &DbString,
property: &DbString,
query: &VectorValue,
options: ApproximateVectorExpansionOptions<'_>,
checker: CancellationChecker<'_>,
) -> Result<Vec<VectorNodeSearchHit>, VectorSearchError>
pub fn approximate_vector_search_expanded_candidates_checked( &self, label: &DbString, property: &DbString, query: &VectorValue, options: ApproximateVectorExpansionOptions<'_>, checker: CancellationChecker<'_>, ) -> Result<Vec<VectorNodeSearchHit>, VectorSearchError>
Lock-free read snapshot wrapper for ANN-root graph expansion.
Sourcepub fn approximate_vector_search_expanded_candidates_batch_checked(
&self,
label: &DbString,
property: &DbString,
queries: &[VectorValue],
options: ApproximateVectorExpansionOptions<'_>,
checker: CancellationChecker<'_>,
) -> Result<Vec<Vec<VectorNodeSearchHit>>, VectorSearchError>
pub fn approximate_vector_search_expanded_candidates_batch_checked( &self, label: &DbString, property: &DbString, queries: &[VectorValue], options: ApproximateVectorExpansionOptions<'_>, checker: CancellationChecker<'_>, ) -> Result<Vec<Vec<VectorNodeSearchHit>>, VectorSearchError>
Lock-free read snapshot wrapper for batched ANN-root graph expansion.
Sourcepub fn score_vector_nodes(
&self,
property: &DbString,
query: &VectorValue,
candidates: &[NodeId],
metric: VectorMetric,
k: usize,
) -> GraphResult<Vec<VectorNodeSearchHit>>
pub fn score_vector_nodes( &self, property: &DbString, query: &VectorValue, candidates: &[NodeId], metric: VectorMetric, k: usize, ) -> GraphResult<Vec<VectorNodeSearchHit>>
Score explicit node candidates in the current snapshot.
This loads one immutable snapshot and delegates to
crate::SeleneGraph::score_vector_nodes.
Sourcepub fn score_vector_nodes_checked(
&self,
property: &DbString,
query: &VectorValue,
candidates: &[NodeId],
metric: VectorMetric,
k: usize,
checker: CancellationChecker<'_>,
) -> Result<Vec<VectorNodeSearchHit>, VectorSearchError>
pub fn score_vector_nodes_checked( &self, property: &DbString, query: &VectorValue, candidates: &[NodeId], metric: VectorMetric, k: usize, checker: CancellationChecker<'_>, ) -> Result<Vec<VectorNodeSearchHit>, VectorSearchError>
Lock-free read snapshot wrapper for
crate::SeleneGraph::score_vector_nodes_checked.
Sourcepub fn score_vector_nodes_batch<C>(
&self,
property: &DbString,
queries: &[VectorValue],
candidate_sets: &[C],
metric: VectorMetric,
k: usize,
) -> GraphResult<Vec<Vec<VectorNodeSearchHit>>>
pub fn score_vector_nodes_batch<C>( &self, property: &DbString, queries: &[VectorValue], candidate_sets: &[C], metric: VectorMetric, k: usize, ) -> GraphResult<Vec<Vec<VectorNodeSearchHit>>>
Score one explicit node candidate set per query in the current snapshot.
This loads one immutable snapshot and delegates to
crate::SeleneGraph::score_vector_nodes_batch.
Sourcepub fn score_vector_nodes_batch_checked<C>(
&self,
property: &DbString,
queries: &[VectorValue],
candidate_sets: &[C],
metric: VectorMetric,
k: usize,
checker: CancellationChecker<'_>,
) -> Result<Vec<Vec<VectorNodeSearchHit>>, VectorSearchError>
pub fn score_vector_nodes_batch_checked<C>( &self, property: &DbString, queries: &[VectorValue], candidate_sets: &[C], metric: VectorMetric, k: usize, checker: CancellationChecker<'_>, ) -> Result<Vec<Vec<VectorNodeSearchHit>>, VectorSearchError>
Lock-free read snapshot wrapper for
crate::SeleneGraph::score_vector_nodes_batch_checked.
Sourcepub fn score_vector_candidate_set(
&self,
property: &DbString,
query: &VectorValue,
candidates: &VectorCandidateSet,
metric: VectorMetric,
k: usize,
) -> GraphResult<Vec<VectorNodeSearchHit>>
pub fn score_vector_candidate_set( &self, property: &DbString, query: &VectorValue, candidates: &VectorCandidateSet, metric: VectorMetric, k: usize, ) -> GraphResult<Vec<VectorNodeSearchHit>>
Score one canonical candidate set against one query in the current snapshot.
This loads one immutable snapshot and delegates to
crate::SeleneGraph::score_vector_candidate_set.
Sourcepub fn score_vector_candidate_set_checked(
&self,
property: &DbString,
query: &VectorValue,
candidates: &VectorCandidateSet,
metric: VectorMetric,
k: usize,
checker: CancellationChecker<'_>,
) -> Result<Vec<VectorNodeSearchHit>, VectorSearchError>
pub fn score_vector_candidate_set_checked( &self, property: &DbString, query: &VectorValue, candidates: &VectorCandidateSet, metric: VectorMetric, k: usize, checker: CancellationChecker<'_>, ) -> Result<Vec<VectorNodeSearchHit>, VectorSearchError>
Lock-free read snapshot wrapper for
crate::SeleneGraph::score_vector_candidate_set_checked.
Sourcepub fn score_vector_candidate_sets_batch(
&self,
property: &DbString,
queries: &[VectorValue],
candidate_sets: &[VectorCandidateSet],
metric: VectorMetric,
k: usize,
) -> GraphResult<Vec<Vec<VectorNodeSearchHit>>>
pub fn score_vector_candidate_sets_batch( &self, property: &DbString, queries: &[VectorValue], candidate_sets: &[VectorCandidateSet], metric: VectorMetric, k: usize, ) -> GraphResult<Vec<Vec<VectorNodeSearchHit>>>
Score one canonical candidate set per query in the current snapshot.
This loads one immutable snapshot and delegates to
crate::SeleneGraph::score_vector_candidate_sets_batch.
Sourcepub fn score_vector_candidate_sets_batch_checked(
&self,
property: &DbString,
queries: &[VectorValue],
candidate_sets: &[VectorCandidateSet],
metric: VectorMetric,
k: usize,
checker: CancellationChecker<'_>,
) -> Result<Vec<Vec<VectorNodeSearchHit>>, VectorSearchError>
pub fn score_vector_candidate_sets_batch_checked( &self, property: &DbString, queries: &[VectorValue], candidate_sets: &[VectorCandidateSet], metric: VectorMetric, k: usize, checker: CancellationChecker<'_>, ) -> Result<Vec<Vec<VectorNodeSearchHit>>, VectorSearchError>
Lock-free read snapshot wrapper for
crate::SeleneGraph::score_vector_candidate_sets_batch_checked.
Sourcepub fn score_vector_neighbors(
&self,
property: &DbString,
query: &VectorValue,
anchor: NodeId,
options: VectorNeighborSearchOptions<'_>,
) -> GraphResult<Vec<VectorNodeSearchHit>>
pub fn score_vector_neighbors( &self, property: &DbString, query: &VectorValue, anchor: NodeId, options: VectorNeighborSearchOptions<'_>, ) -> GraphResult<Vec<VectorNodeSearchHit>>
Score vector-valued neighbors reached from one anchor in the current snapshot.
Sourcepub fn score_vector_neighbors_checked(
&self,
property: &DbString,
query: &VectorValue,
anchor: NodeId,
options: VectorNeighborSearchOptions<'_>,
checker: CancellationChecker<'_>,
) -> Result<Vec<VectorNodeSearchHit>, VectorSearchError>
pub fn score_vector_neighbors_checked( &self, property: &DbString, query: &VectorValue, anchor: NodeId, options: VectorNeighborSearchOptions<'_>, checker: CancellationChecker<'_>, ) -> Result<Vec<VectorNodeSearchHit>, VectorSearchError>
Lock-free read snapshot wrapper for
crate::SeleneGraph::score_vector_neighbors_checked.
Sourcepub fn score_vector_neighbors_batch(
&self,
property: &DbString,
queries: &[VectorValue],
anchors: &[NodeId],
options: VectorNeighborSearchOptions<'_>,
) -> GraphResult<Vec<Vec<VectorNodeSearchHit>>>
pub fn score_vector_neighbors_batch( &self, property: &DbString, queries: &[VectorValue], anchors: &[NodeId], options: VectorNeighborSearchOptions<'_>, ) -> GraphResult<Vec<Vec<VectorNodeSearchHit>>>
Score one anchor’s vector-valued neighbors for each query in the current snapshot.
Sourcepub fn score_vector_neighbors_batch_checked(
&self,
property: &DbString,
queries: &[VectorValue],
anchors: &[NodeId],
options: VectorNeighborSearchOptions<'_>,
checker: CancellationChecker<'_>,
) -> Result<Vec<Vec<VectorNodeSearchHit>>, VectorSearchError>
pub fn score_vector_neighbors_batch_checked( &self, property: &DbString, queries: &[VectorValue], anchors: &[NodeId], options: VectorNeighborSearchOptions<'_>, checker: CancellationChecker<'_>, ) -> Result<Vec<Vec<VectorNodeSearchHit>>, VectorSearchError>
Lock-free read snapshot wrapper for
crate::SeleneGraph::score_vector_neighbors_batch_checked.
Sourcepub fn score_vector_expanded_candidate_sets_batch(
&self,
property: &DbString,
queries: &[VectorValue],
root_sets: &[VectorCandidateSet],
options: VectorNeighborSearchOptions<'_>,
) -> GraphResult<Vec<Vec<VectorNodeSearchHit>>>
pub fn score_vector_expanded_candidate_sets_batch( &self, property: &DbString, queries: &[VectorValue], root_sets: &[VectorCandidateSet], options: VectorNeighborSearchOptions<'_>, ) -> GraphResult<Vec<Vec<VectorNodeSearchHit>>>
Expand one canonical root set per query, then score it in the current snapshot.
This loads one immutable snapshot and delegates to
crate::SeleneGraph::score_vector_expanded_candidate_sets_batch.
Sourcepub fn score_vector_expanded_candidate_sets_batch_checked(
&self,
property: &DbString,
queries: &[VectorValue],
root_sets: &[VectorCandidateSet],
options: VectorNeighborSearchOptions<'_>,
checker: CancellationChecker<'_>,
) -> Result<Vec<Vec<VectorNodeSearchHit>>, VectorSearchError>
pub fn score_vector_expanded_candidate_sets_batch_checked( &self, property: &DbString, queries: &[VectorValue], root_sets: &[VectorCandidateSet], options: VectorNeighborSearchOptions<'_>, checker: CancellationChecker<'_>, ) -> Result<Vec<Vec<VectorNodeSearchHit>>, VectorSearchError>
Lock-free read snapshot wrapper for
crate::SeleneGraph::score_vector_expanded_candidate_sets_batch_checked.
Sourcepub fn vector_neighbor_candidates(
&self,
anchor: NodeId,
edge_label: &DbString,
direction: VectorNeighborDirection,
) -> VectorCandidateSet
pub fn vector_neighbor_candidates( &self, anchor: NodeId, edge_label: &DbString, direction: VectorNeighborDirection, ) -> VectorCandidateSet
Return canonical vector-score candidates reached from one graph anchor in the current snapshot.
Sourcepub fn expand_vector_candidate_set(
&self,
roots: &VectorCandidateSet,
edge_label: &DbString,
direction: VectorNeighborDirection,
) -> VectorCandidateSet
pub fn expand_vector_candidate_set( &self, roots: &VectorCandidateSet, edge_label: &DbString, direction: VectorNeighborDirection, ) -> VectorCandidateSet
Expand canonical candidates through one labeled graph hop in the current snapshot.
Sourcepub fn expand_vector_candidate_set_checked(
&self,
roots: &VectorCandidateSet,
edge_label: &DbString,
direction: VectorNeighborDirection,
checker: CancellationChecker<'_>,
) -> Result<VectorCandidateSet, VectorSearchError>
pub fn expand_vector_candidate_set_checked( &self, roots: &VectorCandidateSet, edge_label: &DbString, direction: VectorNeighborDirection, checker: CancellationChecker<'_>, ) -> Result<VectorCandidateSet, VectorSearchError>
Lock-free read snapshot wrapper for
crate::SeleneGraph::expand_vector_candidate_set_checked.
Sourcepub fn expand_vector_candidate_sets_batch_checked(
&self,
root_sets: &[VectorCandidateSet],
edge_label: &DbString,
direction: VectorNeighborDirection,
k: usize,
checker: CancellationChecker<'_>,
) -> Result<Vec<VectorCandidateSet>, VectorSearchError>
pub fn expand_vector_candidate_sets_batch_checked( &self, root_sets: &[VectorCandidateSet], edge_label: &DbString, direction: VectorNeighborDirection, k: usize, checker: CancellationChecker<'_>, ) -> Result<Vec<VectorCandidateSet>, VectorSearchError>
Expand one canonical root set per query through one graph hop in the current snapshot.
Auto Trait Implementations§
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
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§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.