public interface CommandLine
| Modifier and Type | Method and Description |
|---|---|
Option |
getOption(java.lang.String trigger)
Finds the Option with the specified trigger
|
int |
getOptionCount(Option option)
Retrieves the number of times the specified Option appeared in this
CommandLine
|
int |
getOptionCount(java.lang.String trigger)
Retrieves the number of times the specified Option appeared in this
CommandLine
|
java.util.List |
getOptions()
Retrieves a list of all Options found in this CommandLine
|
java.util.Set |
getOptionTriggers()
Retrieves a list of all Option triggers found in this CommandLine
|
java.util.Set |
getProperties()
Retrieves the set of all property names associated with this CommandLine
|
java.lang.String |
getProperty(java.lang.String property)
Retrieves the value associated with the specified property
|
java.lang.String |
getProperty(java.lang.String property,
java.lang.String defaultValue)
Retrieves the value associated with the specified property
|
java.lang.Boolean |
getSwitch(Option option)
Retrieves the Boolean value associated with the specified Switch
|
java.lang.Boolean |
getSwitch(Option option,
java.lang.Boolean defaultValue)
Retrieves the Boolean value associated with the specified Switch
|
java.lang.Boolean |
getSwitch(java.lang.String trigger)
Retrieves the Boolean value associated with the specified Switch
|
java.lang.Boolean |
getSwitch(java.lang.String trigger,
java.lang.Boolean defaultValue)
Retrieves the Boolean value associated with the specified Switch
|
java.lang.Object |
getValue(Option option)
Retrieves the single Argument value associated with the specified Option
|
java.lang.Object |
getValue(Option option,
java.lang.Object defaultValue)
Retrieves the single Argument value associated with the specified Option
|
java.lang.Object |
getValue(java.lang.String trigger)
Retrieves the single Argument value associated with the specified Option
|
java.lang.Object |
getValue(java.lang.String trigger,
java.lang.Object defaultValue)
Retrieves the single Argument value associated with the specified Option
|
java.util.List |
getValues(Option option)
Retrieves the Argument values associated with the specified Option
|
java.util.List |
getValues(Option option,
java.util.List defaultValues)
Retrieves the Argument values associated with the specified Option
|
java.util.List |
getValues(java.lang.String trigger)
Retrieves the Argument values associated with the specified Option
|
java.util.List |
getValues(java.lang.String trigger,
java.util.List defaultValues)
Retrieves the Argument values associated with the specified Option
|
boolean |
hasOption(Option option)
Detects the presence of an option in this CommandLine.
|
boolean |
hasOption(java.lang.String trigger)
Detects the presence of an option with the specified trigger in this
CommandLine.
|
boolean hasOption(java.lang.String trigger)
trigger - the trigger to search forboolean hasOption(Option option)
option - the Option to search forOption getOption(java.lang.String trigger)
trigger - the name of the option to retrievejava.util.List getValues(java.lang.String trigger)
trigger - a trigger used to lookup the Optionjava.util.List getValues(java.lang.String trigger, java.util.List defaultValues)
trigger - a trigger used to lookup the OptiondefaultValues - the result to return if no values are foundjava.util.List getValues(Option option)
option - the Option associated with the valuesjava.util.List getValues(Option option, java.util.List defaultValues)
option - the Option associated with the valuesdefaultValues - the result to return if no values are foundjava.lang.Object getValue(java.lang.String trigger) throws java.lang.IllegalStateException
trigger - a trigger used to lookup the Optionjava.lang.IllegalStateException - if more than one values are foundjava.lang.Object getValue(java.lang.String trigger, java.lang.Object defaultValue) throws java.lang.IllegalStateException
trigger - a trigger used to lookup the OptiondefaultValue - the result to use if no values are foundjava.lang.IllegalStateException - if more than one values are foundjava.lang.Object getValue(Option option) throws java.lang.IllegalStateException
option - the Option associated with the valuejava.lang.IllegalStateException - if more than one values are foundjava.lang.Object getValue(Option option, java.lang.Object defaultValue) throws java.lang.IllegalStateException
option - the Option associated with the valuedefaultValue - the result to use if no values are foundjava.lang.IllegalStateException - if more than one values are foundjava.lang.Boolean getSwitch(java.lang.String trigger)
trigger - a trigger used to lookup the Optionjava.lang.Boolean getSwitch(java.lang.String trigger, java.lang.Boolean defaultValue)
trigger - a trigger used to lookup the OptiondefaultValue - the Boolean to use if none matchjava.lang.Boolean getSwitch(Option option)
option - the Option associated with the valuejava.lang.Boolean getSwitch(Option option, java.lang.Boolean defaultValue)
option - the Option associated with the valuedefaultValue - the Boolean to use if none matchjava.lang.String getProperty(java.lang.String property)
property - the property name to lookupjava.lang.String getProperty(java.lang.String property, java.lang.String defaultValue)
property - the property name to lookupdefaultValue - the value to use if no other is foundjava.util.Set getProperties()
int getOptionCount(java.lang.String trigger)
trigger - a trigger used to lookup the Optionint getOptionCount(Option option)
option - the Option associated to checkjava.util.List getOptions()
java.util.Set getOptionTriggers()