pub enum Command {
Help,
Quit,
ShowConfig,
ToggleDtr,
ToggleRts,
SendBreak,
SetBaud(u32),
}Expand description
One actionable command produced by CommandKeyParser.
Copy because every variant carries only Copy data (currently a
single u32 for SetBaud). Passing by value is therefore cheap and
matches how the dispatcher consumes the value via match.
Variants§
Help
Show the help / command-key cheatsheet.
Quit
Quit the session.
ShowConfig
Print the current SerialConfig.
ToggleDtr
Toggle the DTR output line.
ToggleRts
Toggle the RTS output line.
SendBreak
Send a line break (~250 ms by default in Issue #7’s handler).
SetBaud(u32)
Apply a new baud rate, parsed from the digits collected after b.
Trait Implementations§
impl Copy for Command
impl Eq for Command
impl StructuralPartialEq for Command
Auto Trait Implementations§
impl Freeze for Command
impl RefUnwindSafe for Command
impl Send for Command
impl Sync for Command
impl Unpin for Command
impl UnsafeUnpin for Command
impl UnwindSafe for Command
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