Enum clargs::ParsingError [−][src]
pub enum ParsingError { UnrecognizedOption(String), AmbiguousOption(String, Vec<String>), AssignmentToFlag(String), AssignmentToFlagAlias(String, String), ParameterDuplication(String), ParameterDuplicationAlias(String, String), MissingArgument(String), MissingArgumentAlias(String, String), UnrecognizedSubcommand(String), AmbiguousSubcommand(String, Vec<String>), MissingRequiredSubcommand, MissingRequiredParameters(Vec<String>), }
Returned when an error occurs during the parsing of an argument list.
Variants
UnrecognizedOption(String)
Indicates that an option was specified which the program does not recognize.
The associated string is the name of the aforementioned option.
AmbiguousOption(String, Vec<String>)
Indicates that a specified option could mean multiple valid options.
The associated string is the name of the aformentioned option. The associated vector of strings contains all the possible valid options.
AssignmentToFlag(String)
Indicates that a value was assigned to an option which does not take a value.
The associated string is the name of the aforementioned option.
AssignmentToFlagAlias(String, String)
Indicates that a value was assigned to an option which does not take a value.
The first associated string is the name of the aforementioned option. The second associated string is the name of the alias which was used to specify the option.
ParameterDuplication(String)
Indicates that a value was assigned to the same option more than once.
The associated string is the name of the aforementioned option.
ParameterDuplicationAlias(String, String)
Indicates that a value was assigned to the same option more than once.
The first associated string is the name of the aforementioned option. The second associated string is the name of the alias which was used to specify the option.
MissingArgument(String)
Indicates that an option was specified which takes a value but didn't get one.
The associated string is the name of the aforementioned option.
MissingArgumentAlias(String, String)
Indicates that an option was specified which takes a value but didn't get one.
The first associated string is the name of the aforementioned option. The second associated string is the name of the alias which was used to specify the option.
UnrecognizedSubcommand(String)
Indicates that a subcommand was specified which the program does not recognize.
The associated string is the name of the aforementioned subcommand.
AmbiguousSubcommand(String, Vec<String>)
Indicates that a specified subcommand could mean multiple valid subcommands.
The associated string is the name of the aformentioned subcommand. The associated vector of strings contains all the possible valid subcommands.
MissingRequiredSubcommand
Indicates that a required subcommand is missing from the argument list.
MissingRequiredParameters(Vec<String>)
Indicates that one or more required options are missing from the argument list.
The associated vector of strings contains all the missing required options.
Trait Implementations
impl PartialEq for ParsingError
[src]
impl PartialEq for ParsingError
fn eq(&self, other: &ParsingError) -> bool
[src]
fn eq(&self, other: &ParsingError) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &ParsingError) -> bool
[src]
fn ne(&self, other: &ParsingError) -> bool
This method tests for !=
.
impl Eq for ParsingError
[src]
impl Eq for ParsingError
impl Display for ParsingError
[src]
impl Display for ParsingError
fn fmt(&self, f: &mut Formatter) -> Result<(), FmtError>
[src]
fn fmt(&self, f: &mut Formatter) -> Result<(), FmtError>
Formats the value using the given formatter. Read more
impl Debug for ParsingError
[src]
impl Debug for ParsingError
fn fmt(&self, f: &mut Formatter) -> Result<(), FmtError>
[src]
fn fmt(&self, f: &mut Formatter) -> Result<(), FmtError>
Formats the value using the given formatter. Read more
impl Error for ParsingError
[src]
impl Error for ParsingError
Auto Trait Implementations
impl Send for ParsingError
impl Send for ParsingError
impl Sync for ParsingError
impl Sync for ParsingError