BasicParser
, GnuParser
, Parser
, PosixParser
public interface CommandLineParser
CommandLineParser
interface
can parse a String array according to the Options
specified
and return a CommandLine
.Modifier and Type | Method | Description |
---|---|---|
CommandLine |
parse(Options options,
java.lang.String[] arguments) |
Parse the arguments according to the specified options.
|
CommandLine |
parse(Options options,
java.lang.String[] arguments,
boolean stopAtNonOption) |
Parse the arguments according to the specified options.
|
CommandLine parse(Options options, java.lang.String[] arguments) throws ParseException
options
- the specified Optionsarguments
- the command line argumentsParseException
- if there are any problems encountered
while parsing the command line tokens.CommandLine parse(Options options, java.lang.String[] arguments, boolean stopAtNonOption) throws ParseException
options
- the specified Optionsarguments
- the command line argumentsstopAtNonOption
- specifies whether to continue parsing the
arguments if a non option is encountered.ParseException
- if there are any problems encountered
while parsing the command line tokens.