Expand description
Command line string parsing support
Functions§
- get_
definition_ parts - Returns
Vec<String>
of definition option parts with two index positions. - is_
definition_ option - Returns boolean for the question “Is
needle
a definition option?”. - is_
double_ hyphen_ option - Returns boolean for the question “Is
needle
a double hyphen option?”. - is_
mops_ option - Returns boolean for the question “Is
needle
a multi-option short syntax (mops) style option argument?” - parse_
definitions - Returns
std::collections::HashMap<String, String>
with key:value mapped as option:definition. - parse_
double_ hyphen_ args - Returns
Options<Vec<String>>
with Vector of arguments following a double hyphen--
command line argument idiom. ReturnsNone
if there was no double hyphen idiom present or there are no arguments following the double hyphen argument. - parse_
first_ arg - Returns
Option<String>
with the first positional argument to the executable. ReturnsNone
if the command was entered as the executable only. - parse_
last_ arg - Returns
Option<String>
with the last positional argument to the executable. ReturnsNone
if the command was entered as the executable only. - parse_
mops - Returns
Option<Vec<String>>
that includes unique short options parsed from the command arguments, including any multi-option short syntax options. ReturnsNone
if there were no short options in the command - parse_
options - Returns
Vec<String>
of command line option arguments in a command line string.