pub struct Path {
pub schema: &'static str,
pub from: String,
pub to: String,
pub found: bool,
pub length: usize,
pub hops: Vec<PathHop>,
}Expand description
A shortest path between two nodes. Edges are followed in either direction (the graph is treated as undirected for reachability), and each hop records the actual direction and provenance of the edge used.
Fields§
§schema: &'static strStable schema tag (SCHEMA).
from: StringNatural key of the start node.
to: StringNatural key of the goal node.
found: boolWhether a path (including the trivial empty one) was found.
length: usizeNumber of hops (edges) in the path; 0 when from == to.
hops: Vec<PathHop>The hops from from to to, in order.
Trait Implementations§
impl StructuralPartialEq for Path
Auto Trait Implementations§
impl Freeze for Path
impl RefUnwindSafe for Path
impl Send for Path
impl Sync for Path
impl Unpin for Path
impl UnsafeUnpin for Path
impl UnwindSafe for Path
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