pub enum Battery {
External,
Level(u8),
Unknown,
}Expand description
How a device reports its battery when a network asks.
Variants§
External
Running from an external supply.
Level(u8)
A level from 1, empty, to 254, full. Values outside that range are clamped into it.
Unknown
The device cannot measure it.
Trait Implementations§
impl Copy for Battery
impl Eq for Battery
impl StructuralPartialEq for Battery
Auto Trait Implementations§
impl Freeze for Battery
impl RefUnwindSafe for Battery
impl Send for Battery
impl Sync for Battery
impl Unpin for Battery
impl UnsafeUnpin for Battery
impl UnwindSafe for Battery
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