Enum cursive::direction::Direction [] [src]

pub enum Direction {
    Abs(Absolute),
    Rel(Relative),
}

Represents a direction, either absolute or orientation-dependent.

  • Absolute directions are Up, Down, Left, and Right.
  • Relative directions are Front and Back.

Variants

An absolute direction.

A direction relative to the current orientation.

Methods

impl Direction
[src]

[src]

Returns the relative direction for the given orientation.

[src]

Returns the absolute direction in the given orientation.

[src]

Shortcut to create Direction::Rel(Relative::Back)

[src]

Shortcut to create Direction::Rel(Relative::Front)

[src]

Shortcut to create Direction::Abs(Absolute::Left)

[src]

Shortcut to create Direction::Abs(Absolute::Right)

[src]

Shortcut to create Direction::Abs(Absolute::Up)

[src]

Shortcut to create Direction::Abs(Absolute::Down)

[src]

Shortcut to create Direction::Abs(Absolute::None)

Trait Implementations

impl Debug for Direction
[src]

[src]

Formats the value using the given formatter. Read more

impl Clone for Direction
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

impl Copy for Direction
[src]

impl PartialEq for Direction
[src]

[src]

This method tests for self and other values to be equal, and is used by ==. Read more

[src]

This method tests for !=.

Auto Trait Implementations

impl Send for Direction

impl Sync for Direction