[][src]Struct oac_parser::spec::Option

pub struct Option {
    pub names_short: Option<Vec<String>>,
    pub names_long: Option<Vec<String>>,
    pub description: Option<String>,
}

Specification of an option - a boolean flag. Examples: --verbose, --dry-run, etc.

Fields

names_short: Option<Vec<String>>

Short option names as they appear in CLI, without prefix. Example: ["s"]

names_long: Option<Vec<String>>

Long option names as they appear in CLI, without prefix. This array SHOULD contain:

  • POSIX long options (long, double-dashed).
  • Legacy (long, single-dashed)
  • Windows-style (long and short, starting with forward slash "/")
  • PowerShell-style options (long, single-dashed) Example: ["simulate", "just-print", "dry-run", "recon", "no-act"]
description: Option<String>

Description of this item.

Trait Implementations

impl Debug for Option[src]

impl<'de> Deserialize<'de> for Option[src]

impl Serialize for Option[src]

Auto Trait Implementations

impl RefUnwindSafe for Option

impl Send for Option

impl Sync for Option

impl Unpin for Option

impl UnwindSafe for Option

Blanket Implementations

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

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

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

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

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

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

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

type Error = Infallible

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.