pub struct Cmd<R, W>{ /* private fields */ }
Expand description
Command interpreter implemented as struct that contains boxed CommandHandlers in a hashmap with Strings as the keys
Implementations§
Source§impl<R, W> Cmd<R, W>
impl<R, W> Cmd<R, W>
Sourcepub fn run(&mut self) -> Result<(), Error>
pub fn run(&mut self) -> Result<(), Error>
Start the command interpreter
Handlers with return code 0 will break the loop
Auto Trait Implementations§
impl<R, W> Freeze for Cmd<R, W>
impl<R, W> !RefUnwindSafe for Cmd<R, W>
impl<R, W> !Send for Cmd<R, W>
impl<R, W> !Sync for Cmd<R, W>
impl<R, W> Unpin for Cmd<R, W>
impl<R, W> !UnwindSafe for Cmd<R, W>
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