Enum stm32f3xx_hal::Switch
source · pub enum Switch {
On,
Off,
}
Expand description
Switch something on or off.
Convenience enum and wrapper around a bool, which more explicit about the intention to enable
or disable something, in comparison to true
or false
.
Variants§
Trait Implementations§
source§impl Ord for Switch
impl Ord for Switch
source§impl PartialEq for Switch
impl PartialEq for Switch
source§impl PartialOrd for Switch
impl PartialOrd for Switch
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Copy for Switch
impl Eq for Switch
impl StructuralEq for Switch
impl StructuralPartialEq for Switch
Auto Trait Implementations§
impl RefUnwindSafe for Switch
impl Send for Switch
impl Sync for Switch
impl Unpin for Switch
impl UnwindSafe for Switch
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