com.github.scli.ParameterParser
the supported option prefixes
Tries to extract the key of an option from the given parameter.
Tries to extract the key of an option from the given parameter. The function checks whether the parameter has one of the prefixes configured for this object. If so, the key without the prefix is returned. Otherwise, result is an empty Option.
the parameter to process
an Option with the key extracted
(Since version ) see corresponding Javadoc for more information.
A data class that stores a list with supported prefixes for options.
When parsing the command line each item is checked whether it starts with one of the prefixes defined by this class. If so, the item is considered an option or a switch.
Command line applications often distinguish between full parameter names and short alias names. The alias has the same meaning as the regular parameter name, but it is shorter to type on the command line. Typically, a different prefix is used distinguish between the long and short parameter names, such as --target-directory for the full name and -d for the short alias. When constructing an instance the prefixes to be managed are specified as ParameterKey objects; hence, it can be stated whether a prefix is used for long or short parameter names.