Struct graphsearch::Vertex
[−]
[src]
pub struct Vertex { pub cost: i32, pub node: usize, }
A vertex between two Node
s with an associated i32
cost and a target node.
Vertex
derives Copy
, Debug
, Eq
and PartialEq
and implements Ord
and
PartialOrd
as we use it ordered compound types.
Fields
cost: i32
cost is defiened as an ì32
, which might change
node: usize
node, an usize
index of the node at the other end of this vertex
Trait Implementations
impl Eq for Vertex
[src]
impl PartialEq for Vertex
[src]
fn eq(&self, __arg_0: &Vertex) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Vertex) -> bool
This method tests for !=
.
impl Debug for Vertex
[src]
impl Ord for Vertex
[src]
fn cmp(&self, other: &Vertex) -> Ordering
This method returns an Ordering
between self
and other
. Read more
impl PartialOrd for Vertex
[src]
fn partial_cmp(&self, other: &Vertex) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
1.0.0
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
1.0.0
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
1.0.0
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
1.0.0
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more