[][src]Enum gridsim::neumann::NeumannDirection

pub enum NeumannDirection {
    Right,
    UpRight,
    Up,
    UpLeft,
    Left,
    DownLeft,
    Down,
    DownRight,
}

Variants

RightUpRightUpUpLeftLeftDownLeftDownDownRight

Methods

impl NeumannDirection[src]

impl NeumannDirection[src]

pub fn delta(self) -> (isize, isize)[src]

Trait Implementations

impl Direction for NeumannDirection[src]

type Directions = NeumannDirectionEnumIterator

fn inv(self) -> Self[src]

All directions should have an opposite direction on the opposite side of its iterator.

fn total() -> usize[src]

The total number of directions.

fn chooser(sigmoids: impl Iterator<Item = f32>) -> Option<(Self, FloatOrd<f32>)>[src]

Must provide an input iterator with length of the number of directions for the Direction impl which contains sigmoid outputs in the range of (0.0, 1.0). This will choose a direction based on the highest sigmoid output. If none of the values are greater than 0.5, then it will choose no direction. Read more

fn chooser_slice(sigmoids: &[f32]) -> Option<(Self, FloatOrd<f32>)>[src]

fn turn_clockwise(self) -> Self[src]

fn turn_counterclockwise(self) -> Self[src]

impl<'a, S, M> TakeMoveDirection<usize, NeumannDirection, M> for SquareGrid<'a, S> where
    S: Sim<'a, Move = M, MoveNeighbors = NeumannNeighbors<M>>, 
[src]

impl PartialEq<NeumannDirection> for NeumannDirection[src]

#[must_use] fn ne(&self, other: &Rhs) -> bool1.0.0[src]

This method tests for !=.

impl Copy for NeumannDirection[src]

impl Eq for NeumannDirection[src]

impl From<usize> for NeumannDirection[src]

impl Into<usize> for NeumannDirection[src]

impl Clone for NeumannDirection[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl<T> Index<NeumannDirection> for NeumannNeighbors<T>[src]

type Output = T

The returned type after indexing.

impl<T> IndexMut<NeumannDirection> for NeumannNeighbors<T>[src]

impl Debug for NeumannDirection[src]

Auto Trait Implementations

Blanket Implementations

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]