|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.commons.cli.Options
databionics.cli.PropertyOptions
public class PropertyOptions
Command line options class enhanced with default values from system properties
Field Summary | |
---|---|
protected java.util.Hashtable |
properties
hashtable for property names |
Constructor Summary | |
---|---|
PropertyOptions()
Defualt constructor |
Method Summary | |
---|---|
void |
add(java.lang.String opt,
java.lang.String longOpt,
boolean hasArg,
boolean isRequired,
java.lang.String description)
Adds a new option with the specified values |
void |
add(java.lang.String opt,
java.lang.String longOpt,
boolean hasArg,
boolean isRequired,
java.lang.String description,
java.lang.String property)
Adds a new option with the specified values |
java.lang.String |
getPropertyValue(java.lang.String opt)
Get a property value for an option |
Methods inherited from class org.apache.commons.cli.Options |
---|
addOption, addOption, addOption, addOptionGroup, getOption, getOptionGroup, getOptions, getRequiredOptions, hasOption, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected java.util.Hashtable properties
Constructor Detail |
---|
public PropertyOptions()
Method Detail |
---|
public void add(java.lang.String opt, java.lang.String longOpt, boolean hasArg, boolean isRequired, java.lang.String description)
opt
- short representation of the optionlongOpt
- the long representation of the optionhasArg
- specifies whether the Option takes an argument or notisRequired
- specifies whether the Option is requireddescription
- describes the function of the option
java.lang.IllegalArgumentException
- if there are any non valid Option characters in
opt
.public void add(java.lang.String opt, java.lang.String longOpt, boolean hasArg, boolean isRequired, java.lang.String description, java.lang.String property)
opt
- short representation of the optionlongOpt
- the long representation of the optionhasArg
- specifies whether the Option takes an argument or notisRequired
- specifies whether the Option is requireddescription
- describes the function of the optionproperty
- the name of the property with the default value
java.lang.IllegalArgumentException
- if there are any non valid Option characters in
opt
.public java.lang.String getPropertyValue(java.lang.String opt)
opt
- the option name
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |