[][src]Struct lorawan::maccommands::ChannelMask

pub struct ChannelMask(_);

ChannelMask represents the ChannelMask from LoRaWAN.

Implementations

impl ChannelMask[src]

pub fn new(data: &[u8]) -> Result<Self, &str>[src]

Constructs a new ChannelMask from the provided data.

pub fn new_from_raw(data: &[u8]) -> Self[src]

Constructs a new ChannelMask from the provided data, without verifying if they are admissible.

Improper use of this method could lead to panic during runtime!

pub fn is_enabled(&self, index: usize) -> Result<bool, &str>[src]

Verifies if a given channel is enabled.

pub fn statuses(&self) -> [bool; 16][src]

Provides information for each of the 16 channels if they are enabled.

Trait Implementations

impl AsRef<[u8]> for ChannelMask[src]

impl Debug for ChannelMask[src]

impl From<[u8; 2]> for ChannelMask[src]

impl PartialEq<ChannelMask> for ChannelMask[src]

impl StructuralPartialEq for ChannelMask[src]

Auto Trait Implementations

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> Same<T> for T

type Output = T

Should always be Self

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.