pub struct EncoderAction { /* private fields */ }Expand description
EncoderAction is the action at a encoder position, stored in encoder_map.
Implementations§
Source§impl EncoderAction
impl EncoderAction
Sourcepub const fn new(clockwise: KeyAction, counter_clockwise: KeyAction) -> Self
pub const fn new(clockwise: KeyAction, counter_clockwise: KeyAction) -> Self
Create a new encoder action.
Sourcepub fn set_clockwise(&mut self, clockwise: KeyAction)
pub fn set_clockwise(&mut self, clockwise: KeyAction)
Set the clockwise action.
Sourcepub fn set_counter_clockwise(&mut self, counter_clockwise: KeyAction)
pub fn set_counter_clockwise(&mut self, counter_clockwise: KeyAction)
Set the counter clockwise action.
Sourcepub fn counter_clockwise(&self) -> KeyAction
pub fn counter_clockwise(&self) -> KeyAction
Get the counter clockwise action.
Trait Implementations§
Source§impl Clone for EncoderAction
impl Clone for EncoderAction
Source§fn clone(&self) -> EncoderAction
fn clone(&self) -> EncoderAction
Returns a duplicate of the value. Read more
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for EncoderAction
impl Debug for EncoderAction
Source§impl Default for EncoderAction
impl Default for EncoderAction
Source§impl<'de> Deserialize<'de> for EncoderAction
impl<'de> Deserialize<'de> for EncoderAction
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl MaxSize for EncoderAction
impl MaxSize for EncoderAction
Source§const POSTCARD_MAX_SIZE: usize = 28usize
const POSTCARD_MAX_SIZE: usize = 28usize
The maximum possible size that the serialization of this
type can have, in bytes.
Source§impl Serialize for EncoderAction
impl Serialize for EncoderAction
impl Copy for EncoderAction
Auto Trait Implementations§
impl Freeze for EncoderAction
impl RefUnwindSafe for EncoderAction
impl Send for EncoderAction
impl Sync for EncoderAction
impl Unpin for EncoderAction
impl UnwindSafe for EncoderAction
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)