pub enum Digit {
Number(u8),
Star,
Pound,
A,
B,
C,
D,
Unknown(u32),
}Expand description
One keypad digit, including the extended A-D symbols.
Variants§
Number(u8)
A numeric digit; valid decoded values are zero through nine.
Star
Pound
A
B
C
D
Unknown(u32)
An unrecognized keypad word retained from the wire.
Implementations§
Source§impl Digit
impl Digit
Sourcepub const fn from_keypad(value: u32) -> Self
pub const fn from_keypad(value: u32) -> Self
Converts a keypad wire word to a typed digit without discarding unknowns.
Sourcepub const fn keypad_value(self) -> u32
pub const fn keypad_value(self) -> u32
Returns the numeric keypad word used on the wire.
Trait Implementations§
impl Copy for Digit
impl Eq for Digit
impl StructuralPartialEq for Digit
Auto Trait Implementations§
impl Freeze for Digit
impl RefUnwindSafe for Digit
impl Send for Digit
impl Sync for Digit
impl Unpin for Digit
impl UnsafeUnpin for Digit
impl UnwindSafe for Digit
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