[][src]Enum plm::Command

pub enum Command {
    On,
    OnFast,
    Off,
    OffFast,
    Ping,
    VersionQuery,
    CancelLinking,
    StartLinking,
    StatusRequest,
    Beep,
    Other(u8),
    None,
}

A Command (two, actually) is sent in a Message. This type has some commonly used ones, but you can send arbitrary values via Command::Other.

Variants

On

When sent to a device, turns the device on. When received, it indicates that the device was turned on by manipulation.

OnFast

When sent to a device, turns the device on faster, e.g. no ramping. When received, it indicates that the device performed a "fast on", usually by a double-tapped switch.

Off

When sent to a device, turns the device off. When received, it indicates that the device was turned off by manipulation.

OffFast

When sent to a device, turns the device off faster, e.g. no ramping. When received, it indicates that the device performed a "fast off", usually by a double-tapped switch.

Ping

Ping the device.

VersionQuery

Retrieves the protocol version information.

CancelLinking

Cancels linking mode for the device.

StartLinking

Starts linking mode for the device.

StatusRequest

Queries the status of the device.

Beep

Causes the device to beep once.

Other(u8)

Arbitrary commands not covered by one of the cases above.

None

Trait Implementations

impl Clone for Command[src]

impl Copy for Command[src]

impl Debug for Command[src]

impl Default for Command[src]

impl Display for Command[src]

impl From<Command> for u8[src]

impl From<u8> for Command[src]

impl PartialEq<Command> for Command[src]

impl StructuralPartialEq for Command[src]

Auto Trait Implementations

impl RefUnwindSafe for Command

impl Send for Command

impl Sync for Command

impl Unpin for Command

impl UnwindSafe for Command

Blanket Implementations

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

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

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

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

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

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

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[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.