trait OptParser extends AnyRef
An option parser defined with a sequence of option definitions.
- Alphabetic
- By Inheritance
- OptParser
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Abstract Value Members
-
abstract
def
<~(args: Seq[String]): OptResult
Parses the given argument sequence and returns a map of option names to option values.
Parses the given argument sequence and returns a map of option names to option values.
Example
val opts = ("timeout", 't') ~> as[Int] ~~ 0 val optr = opts <~ Seq("--timeout", "10", "foo", "bar") // fetch value using either long or short form val timeout = optr[Int]("timeout") val timeout = optr[Int]("t") // get arguments following last option: ("foo", "bar") val rest = optr.args
- args
the argument sequence
- returns
the parse result containing the option value map
- Exceptions thrown
OptException
if an error occurred during parsing
-
abstract
def
opts: Seq[Opt[_]]
Returns the options associated with this parser.
Returns the options associated with this parser.
- returns
the options associated with this parser
Concrete Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )