pub enum GridConnectivity {
FourWay,
EightWay,
Hex,
}Expand description
Grid connectivity type, determines graph-distance metric.
Variants§
FourWay
4-connected (Square4): graph distance = Manhattan |dr| + |dc|.
EightWay
8-connected (Square8): graph distance = Chebyshev max(|dr|, |dc|).
Hex
6-connected hex (Hex2D, axial coords): graph distance = max(|dq|, |dr|, |dq+dr|).
Trait Implementations§
Source§impl Clone for GridConnectivity
impl Clone for GridConnectivity
Source§fn clone(&self) -> GridConnectivity
fn clone(&self) -> GridConnectivity
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for GridConnectivity
impl Debug for GridConnectivity
Source§impl PartialEq for GridConnectivity
impl PartialEq for GridConnectivity
impl Copy for GridConnectivity
impl Eq for GridConnectivity
impl StructuralPartialEq for GridConnectivity
Auto Trait Implementations§
impl Freeze for GridConnectivity
impl RefUnwindSafe for GridConnectivity
impl Send for GridConnectivity
impl Sync for GridConnectivity
impl Unpin for GridConnectivity
impl UnsafeUnpin for GridConnectivity
impl UnwindSafe for GridConnectivity
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> Equivalent<K> for Q
impl<Q, K> Equivalent<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.