Enum argparse_rs::argparser::ArgType [] [src]

pub enum ArgType {
    Option,
    Flag,
    List,
    Dict,
    Positional(u8),
}

This enum represents the different types of arguments supported

Variants

An argument that takes a value, as in ./go --pic lol.jpg

An argument that is a simple flag, as in rustc --version

Like an Option, but takes multiple values, as in ./go --pics 1.png 2.png 3.png

Like a List but takes colon-split key-value pairs, as in ./go --pics Monday:1.jpg Tuesday:2.jpg

A positional argument, as in rustc lib.rs. The u8 indicates The relative position of the position argument (i.e. Positional(0) indicates that this is the first positional argument

Trait Implementations

impl Debug for ArgType
[src]

Formats the value using the given formatter.

impl Clone for ArgType
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl PartialEq for ArgType
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl Display for ArgType
[src]

Formats the value using the given formatter. Read more