[][src]Enum getargs::Error

pub enum Error<'a> {
    UnknownOpt(Opt<'a>),
    RequiresValue(Opt<'a>),
    DoesNotRequireValue(Opt<'a>),
    InvalidValue {
        opt: Opt<'a>,
        desc: String,
        value: &'a str,
    },
    InvalidArg {
        desc: String,
        value: &'a str,
    },
}

A parse error.

Variants

UnknownOpt(Opt<'a>)

An unknown option was passed.

RequiresValue(Opt<'a>)

The option requires a value, but one was not supplied.

DoesNotRequireValue(Opt<'a>)

The option does not require a value, but one was supplied.

InvalidValue

A value for an option could not be parsed.

Fields of InvalidValue

opt: Opt<'a>desc: Stringvalue: &'a str
InvalidArg

A positional argument could not be parsed.

Fields of InvalidArg

desc: Stringvalue: &'a str

Trait Implementations

impl<'a> Clone for Error<'a>[src]

impl<'a> Eq for Error<'a>[src]

impl<'a> PartialEq<Error<'a>> for Error<'a>[src]

impl<'_> Display for Error<'_>[src]

impl<'a> Debug for Error<'a>[src]

impl<'a> StructuralPartialEq for Error<'a>[src]

impl<'a> StructuralEq for Error<'a>[src]

impl<'_> Error for Error<'_>[src]

Auto Trait Implementations

impl<'a> Send for Error<'a>

impl<'a> Sync for Error<'a>

impl<'a> Unpin for Error<'a>

impl<'a> UnwindSafe for Error<'a>

impl<'a> RefUnwindSafe for Error<'a>

Blanket Implementations

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = !

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]