pub struct ArgParser { /* private fields */ }Implementations§
Source§impl ArgParser
impl ArgParser
pub fn new() -> Self
pub fn args(&mut self, arg_type: ArgType, arg_count: ArgCount) -> &mut Self
pub fn flag(&mut self, flags: &[&str]) -> &mut Self
pub fn optional_flag(&mut self, flags: &[&str]) -> &mut Self
pub fn arg_flag(&mut self, flag: &str, arg_type: ArgType) -> &mut Self
pub fn optional_arg_flag(&mut self, flag: &str, arg_type: ArgType) -> &mut Self
pub fn arg_flag_with_default( &mut self, flag: &str, default: &str, arg_type: ArgType, ) -> &mut Self
pub fn short_flag(&mut self, flags: &[&str]) -> &mut Self
pub fn flag_with_default(&mut self, flags: &[&str]) -> &mut Self
pub fn map_short_flag(&self, flag: &str) -> String
pub fn parse(&self, raw_args: &[String]) -> Result<ParsedArgs, Error>
pub fn parse_worker(&self, raw_args: &[String]) -> Result<ParsedArgs, Error>
Auto Trait Implementations§
impl Freeze for ArgParser
impl RefUnwindSafe for ArgParser
impl Send for ArgParser
impl Sync for ArgParser
impl Unpin for ArgParser
impl UnwindSafe for ArgParser
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