Struct getopt_rs::Opt[][src]

pub struct Opt<'a> {
    pub long_rule: LongForm,
    pub short: char,
    pub long: Option<&'a str>,
    pub no_short: bool,
}
Expand description

A command line option rule.

At least one option form must be present, short and long cannot both be None.

Fields

long_rule: LongForm

The long-option rule, telling how long options should be parsed.

Default: LongForm::DoubleDash.

short: char

The short form and identifier for the option.

long: Option<&'a str>

The long form for the option.

Default: None.

no_short: bool

Disallow the short form.

Default: false.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.