|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.commons.betwixt.Options
Collective for Betwixt
optional behaviour hints.
An option links a name with a value (both strings).
Field Summary | |
private static java.lang.String[] |
EMPTY_STRING_ARRAY
Empty string array for use with toArray |
private java.util.HashMap |
valuesByName
Option values indexed by name |
Constructor Summary | |
Options()
|
Method Summary | |
void |
addOption(java.lang.String name,
java.lang.String value)
Adds the option. |
java.lang.String[] |
getNames()
Gets the names of each option. |
java.lang.String |
getValue(java.lang.String name)
Gets the value (if any) associated with the given name. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static final java.lang.String[] EMPTY_STRING_ARRAY
private java.util.HashMap valuesByName
Constructor Detail |
public Options()
Method Detail |
public java.lang.String getValue(java.lang.String name)
name
- String
, not null
public java.lang.String[] getNames()
String
array containing the name of each optionpublic void addOption(java.lang.String name, java.lang.String value)
name
- String
name, not nullvalue
- Strong
name, not null
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |