pub trait Input {
// Required methods
fn parsed(&self) -> bool;
fn has_default(&self) -> bool;
fn parse(&mut self, token: &str) -> CliResult<bool>;
fn display_name(&self) -> String;
fn description(&self) -> Option<String>;
fn type_name(&self) -> InputType;
fn is_bool_flag(&self) -> bool;
fn complete(&mut self, value: &str) -> CliResult<Vec<String>>;
}Expand description
parser complexities:
compound flags (-am)
optional flags
out of order flags
Required Methods§
fn parsed(&self) -> bool
fn has_default(&self) -> bool
fn parse(&mut self, token: &str) -> CliResult<bool>
fn display_name(&self) -> String
fn description(&self) -> Option<String>
fn type_name(&self) -> InputType
fn is_bool_flag(&self) -> bool
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".