|
|
|||||||||||||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||||||||||||
java.lang.Objectde.lmu.ifi.dbs.elki.logging.AbstractLoggable
de.lmu.ifi.dbs.elki.utilities.optionhandling.Option<Boolean>
de.lmu.ifi.dbs.elki.utilities.optionhandling.Flag
public class Flag
Option class specifying a flag object.
A flag object is optional parameter which can be set (value "true") or not (value "false").
| Field Summary | |
|---|---|
static String |
NOT_SET
Constant indicating that the flag is not set. |
static String |
SET
Constant indicating that the flag is set. |
| Fields inherited from class de.lmu.ifi.dbs.elki.utilities.optionhandling.Option |
|---|
name, shortDescription, value |
| Fields inherited from class de.lmu.ifi.dbs.elki.logging.AbstractLoggable |
|---|
debug |
| Constructor Summary | |
|---|---|
Flag(OptionID optionID)
Constructs a flag object with the given optionID. |
|
Flag(String name,
String description)
Deprecated. |
|
| Method Summary | |
|---|---|
String |
getDescription()
Returns the short description of this flag. |
boolean |
isSet()
Returns true if the flag is set, false otherwise. |
boolean |
isValid(String value)
Checks if the given argument is valid for this option. |
void |
setValue(boolean value)
Specifies if the flag is set or not. |
void |
setValue(String value)
Specifies if the flag is set or not. |
| Methods inherited from class de.lmu.ifi.dbs.elki.utilities.optionhandling.Option |
|---|
getName, getShortDescription, getValue, setShortDescription |
| Methods inherited from class de.lmu.ifi.dbs.elki.logging.AbstractLoggable |
|---|
debugFine, debugFiner, debugFinest, exception, message, progress, progress, progress, verbose, verbose, warning |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String SET
public static final String NOT_SET
| Constructor Detail |
|---|
public Flag(OptionID optionID)
optionID - the unique id of the option
@Deprecated
public Flag(String name,
String description)
name - the name of the flag.description - the description of the flag.| Method Detail |
|---|
public String getDescription()
getDescription in class Option<Boolean>Option.getDescription()public boolean isSet()
isSet in class Option<Boolean>Option.isSet()
public void setValue(String value)
throws ParameterException
SET or NOT_SET.
setValue in class Option<Boolean>value - the option's value to be set
ParameterException - if the given value is not a valid value for this option.Option.setValue(java.lang.String)public void setValue(boolean value)
value - true, if the flag is set, false otherwise
public boolean isValid(String value)
throws ParameterException
Option
isValid in class Option<Boolean>value - option value to be checked
ParameterException - if the given value is not a valid value for this option.Option.isValid(java.lang.String)
|
|
||||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||||