Enum e_drone::system::FlightEvent
source · [−]#[repr(u8)]
pub enum FlightEvent {
Show 13 variants
None,
Stop,
Takeoff,
Landing,
Reverse,
FlipFront,
FlipRear,
FlipLeft,
FlipRight,
ReturnHone,
Shot,
UnderAttack,
ResetHeading,
}
Variants
None
Stop
Takeoff
Landing
Reverse
FlipFront
FlipRear
FlipLeft
FlipRight
ReturnHone
Shot
UnderAttack
ResetHeading
Implementations
sourceimpl FlightEvent
impl FlightEvent
pub fn from_u8(data_u8: u8) -> FlightEvent
Trait Implementations
sourceimpl Clone for FlightEvent
impl Clone for FlightEvent
sourcefn clone(&self) -> FlightEvent
fn clone(&self) -> FlightEvent
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for FlightEvent
impl Debug for FlightEvent
sourceimpl From<FlightEvent> for u8
impl From<FlightEvent> for u8
sourcefn from(enum_value: FlightEvent) -> Self
fn from(enum_value: FlightEvent) -> Self
Converts to this type from the input type.
sourceimpl PartialEq<FlightEvent> for FlightEvent
impl PartialEq<FlightEvent> for FlightEvent
sourceimpl TryFrom<u8> for FlightEvent
impl TryFrom<u8> for FlightEvent
type Error = TryFromPrimitiveError<FlightEvent>
type Error = TryFromPrimitiveError<FlightEvent>
The type returned in the event of a conversion error.
sourcefn try_from(number: u8) -> Result<Self, TryFromPrimitiveError<Self>>
fn try_from(number: u8) -> Result<Self, TryFromPrimitiveError<Self>>
Performs the conversion.
sourceimpl TryFromPrimitive for FlightEvent
impl TryFromPrimitive for FlightEvent
type Primitive = u8
const NAME: &'static str = "FlightEvent"
fn try_from_primitive(
number: Self::Primitive
) -> Result<Self, TryFromPrimitiveError<Self>>
impl Copy for FlightEvent
impl Eq for FlightEvent
impl StructuralEq for FlightEvent
impl StructuralPartialEq for FlightEvent
Auto Trait Implementations
impl RefUnwindSafe for FlightEvent
impl Send for FlightEvent
impl Sync for FlightEvent
impl Unpin for FlightEvent
impl UnwindSafe for FlightEvent
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more