Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Methods for creation an Option
Options options = new Options();
// create the simple option without using the OptionBuilder
options.addOption("o", "opt", false, "An option, no args");
// simple help option using the builder
// an option with a value separator, defaults to =
.withDescription("Java style property")
// an option with an argument, no short version, and is required
.withArgName("input-file") // also need hasArg() or won't work
.withDescription("The input file")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.