Struct combu::flag::Flag [−][src]
pub struct Flag { pub name: String, pub description: String, pub short_alias: Vector<char>, pub long_alias: Vector<String>, pub default_value: FlagValue, pub flag_type: FlagType, }
Expand description
Struct for Flag setting’s information
Fields
name: String
This flag’s name
description: String
This flag’s description
short_alias: Vector<char>
Vector of this flag’s short alias
long_alias: Vector<String>
Vector of this flag’s long alias
default_value: FlagValue
This flag’s default value
flag_type: FlagType
This flag’s flag_type
Implementations
Creates a new instance of Flag
Builds a new instance of Flags with all options.
Creates a new instance of Flag with name and type
Creates a new instance of string Flag
Add an short alias to this Flag
Set this flag’s default value
Set this flag’s description
Returns positions alias in aliases matches one of short alias.
Get this Flag’s name’s clone
Derives this Flag’s value from arg Alias of self.flag_type.get_value_from_string(arg)
Derives this Flag’s value in case of no value Alias of self.flag_type.get_value_if_no_value()
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Flag
impl UnwindSafe for Flag
Blanket Implementations
Mutably borrows from an owned value. Read more