pub enum CsrSnapshotError<NodeIndex, EdgeIndex> {
MissingOffsets,
MissingTargets,
OffsetsVersion {
kind: u32,
expected: u32,
actual: u32,
},
TargetsVersion {
kind: u32,
expected: u32,
actual: u32,
},
OffsetsView(SectionViewError),
TargetsView(SectionViewError),
OffsetsEmpty,
NodeCountOverflow {
offsets_len: usize,
},
Csr(CsrError<NodeIndex, EdgeIndex>),
}Expand description
Error returned when a snapshot cannot be opened as a CSR graph.
§Performance
perf: unspecified; errors are returned only from snapshot-bound paths.
Variants§
MissingOffsets
The snapshot has no CSR offsets section for the requested edge width.
MissingTargets
The snapshot has no CSR targets section for the requested node width.
OffsetsVersion
The CSR offsets section was present but its version did not match.
Fields
TargetsVersion
The CSR targets section was present but its version did not match.
Fields
OffsetsView(SectionViewError)
The CSR offsets section payload could not be borrowed as the selected little-endian index word slice.
TargetsView(SectionViewError)
The CSR targets section payload could not be borrowed as the selected little-endian index word slice.
OffsetsEmpty
The CSR offsets section is empty; CSR requires at least one entry for the n-plus-one layout.
NodeCountOverflow
The derived node count would not fit in the selected index type.
Csr(CsrError<NodeIndex, EdgeIndex>)
CSR-shape validation failed on the borrowed sections.
Trait Implementations§
Source§impl<NodeIndex: Clone, EdgeIndex: Clone> Clone for CsrSnapshotError<NodeIndex, EdgeIndex>
impl<NodeIndex: Clone, EdgeIndex: Clone> Clone for CsrSnapshotError<NodeIndex, EdgeIndex>
Source§fn clone(&self) -> CsrSnapshotError<NodeIndex, EdgeIndex>
fn clone(&self) -> CsrSnapshotError<NodeIndex, EdgeIndex>
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl<NodeIndex, EdgeIndex> Display for CsrSnapshotError<NodeIndex, EdgeIndex>
impl<NodeIndex, EdgeIndex> Display for CsrSnapshotError<NodeIndex, EdgeIndex>
Source§impl<NodeIndex, EdgeIndex> Error for CsrSnapshotError<NodeIndex, EdgeIndex>
impl<NodeIndex, EdgeIndex> Error for CsrSnapshotError<NodeIndex, EdgeIndex>
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Source§impl<NodeIndex, EdgeIndex> From<CsrError<NodeIndex, EdgeIndex>> for CsrSnapshotError<NodeIndex, EdgeIndex>
impl<NodeIndex, EdgeIndex> From<CsrError<NodeIndex, EdgeIndex>> for CsrSnapshotError<NodeIndex, EdgeIndex>
Source§impl<NodeIndex: PartialEq, EdgeIndex: PartialEq> PartialEq for CsrSnapshotError<NodeIndex, EdgeIndex>
impl<NodeIndex: PartialEq, EdgeIndex: PartialEq> PartialEq for CsrSnapshotError<NodeIndex, EdgeIndex>
Source§fn eq(&self, other: &CsrSnapshotError<NodeIndex, EdgeIndex>) -> bool
fn eq(&self, other: &CsrSnapshotError<NodeIndex, EdgeIndex>) -> bool
self and other values to be equal, and is used by ==.