net.sf.saffron.util
Class OptionsList.StringOption

java.lang.Object
  |
  +--net.sf.saffron.util.OptionsList.Option
        |
        +--net.sf.saffron.util.OptionsList.StringOption
Enclosing class:
OptionsList

public static class OptionsList.StringOption
extends OptionsList.Option


Field Summary
 
Fields inherited from class net.sf.saffron.util.OptionsList.Option
value_
 
Constructor Summary
OptionsList.StringOption(String flag, String option, String description, boolean required, boolean anonymous, String defaultValue, OptionsList.OptionHandler handler)
           
 
Method Summary
protected  void readArg(String arg)
          Converts an argument to the correct value type, and acts on the value.
 String stringValue()
           
 
Methods inherited from class net.sf.saffron.util.OptionsList.Option
getDescription, getName, getValue, match, set, setHandler, valueError
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OptionsList.StringOption

public OptionsList.StringOption(String flag,
                                String option,
                                String description,
                                boolean required,
                                boolean anonymous,
                                String defaultValue,
                                OptionsList.OptionHandler handler)
Method Detail

stringValue

public String stringValue()

readArg

protected void readArg(String arg)
Description copied from class: OptionsList.Option
Converts an argument to the correct value type, and acts on the value.

What action is taken depends upon whether the value is valid for this argument type, and whether there is a handler. If there is a handler, this method calls either OptionsList.OptionHandler.set(net.sf.saffron.util.OptionsList.Option, java.lang.Object, boolean) or OptionsList.OptionHandler.invalidValue(net.sf.saffron.util.OptionsList.Option, java.lang.String). If there is no handler, the method should execute a reasonable default action like assigning to a field via reflection.

Specified by:
readArg in class OptionsList.Option
Parameters:
arg -

SourceForge.net_Logo