org.clapper.argot

SingleValueOption

class SingleValueOption [T] extends CommandLineOption[T] with SingleValueArg[T]

Class for an option that takes a single value.

Linear Supertypes
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Hide All
  2. Show all
  1. SingleValueOption
  2. SingleValueArg
  3. HasValue
  4. CommandLineOption
  5. CommandLineArgument
  6. AnyRef
  7. Any
Visibility
  1. Public
  2. All

Instance Constructors

  1. new SingleValueOption (parent: ArgotParser, names: List[String], valueName: String, description: String, convert: (String, SingleValueOption[T]) ⇒ T)

    parent

    the parent parser instance that owns the option

    names

    the list of names the option is known by

    valueName

    the placeholder name for the option's value, for the usage message

    description

    textual description of the option

    convert

    a function that will convert a string value for the option to an appropriate value of type T.

Value Members

  1. def != (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  2. def != (arg0: Any): Boolean

    Attributes
    final
    Definition Classes
    Any
  3. def ## (): Int

    Attributes
    final
    Definition Classes
    AnyRef → Any
  4. def == (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  5. def == (arg0: Any): Boolean

    Attributes
    final
    Definition Classes
    Any
  6. def asInstanceOf [T0] : T0

    Attributes
    final
    Definition Classes
    Any
  7. def clone (): AnyRef

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  8. val convert : (String, SingleValueOption[T]) ⇒ T

    a function that will convert a string value for the option to an appropriate value of type T.

  9. def convertString (s: String): T

    Method that converts a string value to type T.

    Method that converts a string value to type T. Should throw ArgotConversionException on error.

    s

    the string to convert

    returns

    the converted result

    Definition Classes
    SingleValueOptionHasValue
  10. val description : String

    textual description of the option

    textual description of the option

    Definition Classes
    SingleValueOptionCommandLineArgument
  11. def eq (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  12. def equals (o: Any): Boolean

    The standard equals() method.

    The standard equals() method.

    o

    some other object

    returns

    true if the other object is the same class and is equivalent, false if not.

    Definition Classes
    CommandLineArgument → AnyRef → Any
  13. def finalize (): Unit

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  14. def getClass (): java.lang.Class[_]

    Attributes
    final
    Definition Classes
    AnyRef → Any
  15. val hasValue : Boolean

    Always true, indicating that HasValue classes always have an associated value.

    Always true, indicating that HasValue classes always have an associated value.

    Definition Classes
    HasValueCommandLineArgument
  16. def hashCode (): Int

    Calculate the hash code for the object.

    Calculate the hash code for the object. The default implementation returns the hash code of the key.

    returns

    the hash code

    Definition Classes
    CommandLineArgument → AnyRef → Any
    See also

    #key

  17. def isInstanceOf [T0] : Boolean

    Attributes
    final
    Definition Classes
    Any
  18. def key : String

    Return an object that represents the key for this parameter, suitable for hashing, sorting, etc.

    Return an object that represents the key for this parameter, suitable for hashing, sorting, etc. They key for a command line option is the result of calling name().

    returns

    the key

    Attributes
    protected
    Definition Classes
    CommandLineOptionCommandLineArgument
  19. def name : String

    Return a suitable name for the option.

    Return a suitable name for the option. The returned name will have a "-" or "--" prefix, depending on whether it's long or short. It will be based on the first option in the list of option names.

    returns

    the option name

    Definition Classes
    CommandLineOptionCommandLineArgument
  20. val names : List[String]

    the list of names the option is known by

    the list of names the option is known by

    Definition Classes
    SingleValueOptionCommandLineOption
  21. def ne (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  22. def notify (): Unit

    Attributes
    final
    Definition Classes
    AnyRef
  23. def notifyAll (): Unit

    Attributes
    final
    Definition Classes
    AnyRef
  24. val parent : ArgotParser

    the parent parser instance that owns the option

    the parent parser instance that owns the option

    Definition Classes
    SingleValueOptionCommandLineArgument
  25. def reset (): Unit

    Resets the internal state of the argument to what it was right after construction, undoing the effects of any parse operation.

    Resets the internal state of the argument to what it was right after construction, undoing the effects of any parse operation.

    Definition Classes
    SingleValueArgCommandLineArgument
  26. def setFromString (s: String): Unit

    Given a string value, convert the value to type T by calling convert(), then store it by calling storeValue().

    Given a string value, convert the value to type T by calling convert(), then store it by calling storeValue().

    s

    the string to convert

    Definition Classes
    HasValue
  27. val supportsMultipleValues : Boolean

    Whether or not the class supports multiple values (e.

    Whether or not the class supports multiple values (e.g., a sequence) or just one.

    Definition Classes
    SingleValueArgHasValue
  28. def synchronized [T0] (arg0: ⇒ T0): T0

    Attributes
    final
    Definition Classes
    AnyRef
  29. def toString (): String

    Get a printable name for this object.

    Get a printable name for this object.

    returns

    the printable name

    Definition Classes
    CommandLineOption → AnyRef → Any
  30. def value : Option[T]

    Get the option's value.

    Get the option's value.

    returns

    Some(value) if the value is set; None if not.

    Definition Classes
    SingleValueArg
  31. val valueName : String

    the placeholder name for the option's value, for the usage message

    the placeholder name for the option's value, for the usage message

    Definition Classes
    SingleValueOptionHasValue
  32. def wait (): Unit

    Attributes
    final
    Definition Classes
    AnyRef
    Annotations
    @throws()
  33. def wait (arg0: Long, arg1: Int): Unit

    Attributes
    final
    Definition Classes
    AnyRef
    Annotations
    @throws()
  34. def wait (arg0: Long): Unit

    Attributes
    final
    Definition Classes
    AnyRef
    Annotations
    @throws()

Inherited from SingleValueArg[T]

Inherited from HasValue[T]

Inherited from CommandLineOption[T]

Inherited from CommandLineArgument[T]

Inherited from AnyRef

Inherited from Any