public abstract class RunnableOption extends Option
RunnableOption class extends Apache's {#link Option} class
in order to provide the option to embed the running logic inside the option
itself.Option.BuilderUNINITIALIZED, UNLIMITED_VALUES| Constructor and Description |
|---|
RunnableOption(String opt,
boolean hasArg,
String description)
Instantiates a new
RunnableOption object. |
RunnableOption(String opt,
String description)
Instantiates a new
RunnableOption object. |
RunnableOption(String opt,
String longOpt,
boolean hasArg,
String description)
Instantiates a new
RunnableOption object. |
RunnableOption(String opt,
String longOpt,
int numArgs,
String description)
Instantiates a new
RunnableOption object. |
| Modifier and Type | Method and Description |
|---|---|
abstract void |
run(CommandLine line)
Runs this particular option based on the provided command line.
|
addValue, builder, builder, clone, equals, getArgName, getArgs, getDescription, getId, getLongOpt, getOpt, getType, getValue, getValue, getValue, getValues, getValueSeparator, getValuesList, hasArg, hasArgName, hasArgs, hashCode, hasLongOpt, hasOptionalArg, hasValueSeparator, isRequired, setArgName, setArgs, setDescription, setLongOpt, setOptionalArg, setRequired, setType, setType, setValueSeparator, toStringpublic RunnableOption(String opt, boolean hasArg, String description) throws IllegalArgumentException
RunnableOption object.opt - short representation of the optionhasArg - specifies whether the Option takes an argument or notdescription - describes the function of the optionIllegalArgumentException - if there are any non valid
Option characters in opt.public RunnableOption(String opt, String longOpt, boolean hasArg, String description) throws IllegalArgumentException
RunnableOption object.opt - short representation of the optionlongOpt - the long representation of the optionhasArg - specifies whether the Option takes an argument or notdescription - describes the function of the optionIllegalArgumentException - if there are any non valid
Option characters in opt.public RunnableOption(String opt, String longOpt, int numArgs, String description) throws IllegalArgumentException
RunnableOption object.opt - short representation of the optionlongOpt - the long representation of the optionnumArgs - specifies the number of arguments the Option takesdescription - describes the function of the optionIllegalArgumentException - if there are any non valid
Option characters in opt.public RunnableOption(String opt, String description) throws IllegalArgumentException
RunnableOption object.opt - short representation of the optiondescription - describes the function of the optionIllegalArgumentException - if there are any non valid
Option characters in opt.public abstract void run(CommandLine line) throws Exception
line - the command line for which to run this optionException - if an error occurred while running the command optionCopyright (C) 2015-2015 The Helenus Driver Project Authors.