#[repr(u8)]pub enum Direction {
North = 0,
East = 1,
South = 2,
West = 3,
}
Expand description
The four cardinal directions: North, East, South, and West.
Variants§
Implementations§
Source§impl Direction
impl Direction
Sourcepub const fn is_vertical(self) -> bool
pub const fn is_vertical(self) -> bool
Returns true if the Direction
is North
or South
.
Sourcepub const fn is_horizontal(self) -> bool
pub const fn is_horizontal(self) -> bool
Returns true if the Direction
is East
or West
.
Trait Implementations§
Source§impl Mul<Transform> for Direction
impl Mul<Transform> for Direction
Source§impl MulAssign<Transform> for Direction
impl MulAssign<Transform> for Direction
Source§fn mul_assign(&mut self, rhs: Transform)
fn mul_assign(&mut self, rhs: Transform)
Applies a Transform
to the current Direction
.
Source§impl TryFromPrimitive for Direction
impl TryFromPrimitive for Direction
impl Copy for Direction
impl Eq for Direction
impl StructuralPartialEq for Direction
Auto Trait Implementations§
impl Freeze for Direction
impl RefUnwindSafe for Direction
impl Send for Direction
impl Sync for Direction
impl Unpin for Direction
impl UnwindSafe for Direction
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