pub struct Path<W> {
pub origin_cell: H3Cell,
pub destination_cell: H3Cell,
pub cost: W,
pub directed_edge_path: DirectedEdgePath,
}
Expand description
Path describes a path between a cell and another with an associated cost
Fields§
§origin_cell: H3Cell
The cell the path starts at.
This is the cell the path was calculated from. The actual start cell of the
path may differ in case origin_cell
is not directly connected to the graph
destination_cell: H3Cell
The cell the path ends at.
This is the cell the path was calculated to. The actual end cell of the
path may differ in case destination_cell
is not directly connected to the graph
cost: W
§directed_edge_path: DirectedEdgePath
describes the path
Implementations§
Trait Implementations§
Source§impl<'de, W> Deserialize<'de> for Path<W>where
W: Deserialize<'de>,
impl<'de, W> Deserialize<'de> for Path<W>where
W: Deserialize<'de>,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl<W> Ord for Path<W>where
W: Ord,
order by cost, origin index and destination_index.
impl<W> Ord for Path<W>where
W: Ord,
order by cost, origin index and destination_index.
This ordering can used to bring Vec
s of routes in a deterministic order to make them
comparable
Source§impl<W> PartialOrd for Path<W>where
W: Ord,
impl<W> PartialOrd for Path<W>where
W: Ord,
Source§impl<W> TryFrom<(DirectedEdgePath, W)> for Path<W>
impl<W> TryFrom<(DirectedEdgePath, W)> for Path<W>
impl<W: Eq> Eq for Path<W>
impl<W> StructuralPartialEq for Path<W>
Auto Trait Implementations§
impl<W> Freeze for Path<W>where
W: Freeze,
impl<W> RefUnwindSafe for Path<W>where
W: RefUnwindSafe,
impl<W> Send for Path<W>where
W: Send,
impl<W> Sync for Path<W>where
W: Sync,
impl<W> Unpin for Path<W>where
W: Unpin,
impl<W> UnwindSafe for Path<W>where
W: UnwindSafe,
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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>
Converts
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>
Converts
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 more