pub struct Shell<Info>where
Info: Clone,{ /* private fields */ }Implementations§
Source§impl<Info> Shell<Info>where
Info: Clone,
impl<Info> Shell<Info>where
Info: Clone,
pub fn new(info: Info) -> Self
pub fn set_line_reader<P>(self, linereader: P) -> Selfwhere
P: LineReader + Sized + 'static,
pub fn add_command<C>(self, command: C) -> Selfwhere
C: CommandMetadata<Info> + Sized + 'static,
pub fn add_subcommand<SubcommandInfo>(
self,
namespace: &str,
commands: SubcommandList<SubcommandInfo>,
) -> Selfwhere
SubcommandInfo: Clone + 'static,
pub async fn run(self)
Auto Trait Implementations§
impl<Info> Freeze for Shell<Info>where
Info: Freeze,
impl<Info> !RefUnwindSafe for Shell<Info>
impl<Info> !Send for Shell<Info>
impl<Info> !Sync for Shell<Info>
impl<Info> Unpin for Shell<Info>where
Info: Unpin,
impl<Info> !UnwindSafe for Shell<Info>
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more