pub struct BellmanFordResult {
pub distances: HashMap<NodeId, f64>,
pub parents: HashMap<NodeId, NodeId>,
}Expand description
Result of a Bellman-Ford shortest-path search.
Fields§
§distances: HashMap<NodeId, f64>Map from NodeId to the shortest distance from the source.
Nodes not reachable from the source are absent.
parents: HashMap<NodeId, NodeId>Parent of each node in the shortest-path tree.
Auto Trait Implementations§
impl Freeze for BellmanFordResult
impl RefUnwindSafe for BellmanFordResult
impl Send for BellmanFordResult
impl Sync for BellmanFordResult
impl Unpin for BellmanFordResult
impl UnwindSafe for BellmanFordResult
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