pub struct Node<T> {
pub cmd: String,
pub callback: Option<Box<CallBack<T>>>,
/* private fields */
}Fields§
§cmd: String§callback: Option<Box<CallBack<T>>>Implementations§
Source§impl<T> Node<T>
impl<T> Node<T>
pub fn new( cmd: &str, conditional: Option<&str>, help: &str, callback: Option<Box<CallBack<T>>>, ) -> Node<T>
pub fn add_node(&mut self, node: Node<T>)
pub fn add_arg(&mut self, arg: &str, required: bool)
pub fn find(&self, cmd: &str) -> Option<&Node<T>>
pub fn get_suggestions( &self, levels: Vec<&str>, idx: usize, _nr_required: usize, ) -> Option<Vec<&str>>
pub fn args(&self) -> &Option<Vec<(String, bool)>>
pub fn print_help(&self, level: u8)
Auto Trait Implementations§
impl<T> Freeze for Node<T>
impl<T> !RefUnwindSafe for Node<T>
impl<T> !Send for Node<T>
impl<T> !Sync for Node<T>
impl<T> Unpin for Node<T>
impl<T> !UnwindSafe for Node<T>
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