public class Getopt
extends java.lang.Object
Constructor and Description |
---|
Getopt(java.lang.String[] args)
Constructor
|
Getopt(java.lang.String[] args,
java.lang.String prefix)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
boolean |
contains(java.lang.String option) |
boolean |
getBooleanValue(java.lang.String option)
Returns the boolean value for the given option.
|
boolean |
getBooleanValue(java.lang.String option,
boolean defaultValue)
Returns the boolean value for the given option.
|
java.lang.String |
getStringValue(java.lang.String option)
Returns the string value for the given option.
|
java.lang.String |
getStringValue(java.lang.String option,
java.lang.String defaultValue)
Returns the string value for the given option.
|
int |
length() |
public Getopt(java.lang.String[] args)
args
- the command line parameterspublic Getopt(java.lang.String[] args, java.lang.String prefix)
args
- the command line parametersprefix
- the prefix for command line paramterspublic boolean contains(java.lang.String option)
option
- the option we are looking forpublic int length()
public java.lang.String getStringValue(java.lang.String option)
option
- the optionpublic java.lang.String getStringValue(java.lang.String option, java.lang.String defaultValue)
option
- the optiondefaultValue
- the default value if the option is not definedpublic boolean getBooleanValue(java.lang.String option)
option
- the optionpublic boolean getBooleanValue(java.lang.String option, boolean defaultValue)
option
- the optiondefaultValue
- the default value if the option is not definedCopyright © 2000-2013 Apache Software Foundation. All Rights Reserved.