Module commandlines::parsers
source · Expand description
Command line string parsing support
Functions
Returns
Vec<String> of definition option parts with two index positions.Returns boolean for the question “Is
needle a definition option?”.Returns boolean for the question “Is
needle a double hyphen option?”.Returns boolean for the question “Is
needle a multi-option short syntax (mops) style option argument?”Returns
std::collections::HashMap<String, String> with key:value mapped as option:definition.Returns
Options<Vec<String>> with Vector of arguments following a double dash -- command line argument idiom.
Returns None if there was no double dash idiom present or there are no arguments following the double dash argument.Returns
Option<String> with the first positional argument to the executable.
Returns None if the command was entered as the executable only.Returns
Option<String> with the last positional argument to the executable.
Returns None if the command was entered as the executable only.Returns
Option<Vec<String>> that includes unique short options parsed from the command arguments, including any multi-option short syntax options.
Returns None if there were no short options in the commandReturns
Vec<String> of command line option arguments in a command line string.