Class

caseapp.core.parser

ConsParser

Related Doc: package parser

Permalink

final case class ConsParser[H, T <: HList, DT <: HList](arg: Arg, argParser: ArgParser[H], default: () ⇒ Option[H], tail: Aux[T, DT]) extends Parser[::[H, T]] with Product with Serializable

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ConsParser
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. Parser
  7. AnyRef
  8. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new ConsParser(arg: Arg, argParser: ArgParser[H], default: () ⇒ Option[H], tail: Aux[T, DT])

    Permalink

Type Members

  1. type D = ::[Option[H], DT]

    Permalink

    Intermediate result type.

    Intermediate result type.

    Used during parsing, while checking the arguments one after the other.

    If parsing succeeds, a T can be built from the D at the end of parsing.

    Definition Classes
    ConsParserParser

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. val arg: Arg

    Permalink
  5. val argParser: ArgParser[H]

    Permalink
  6. val args: Seq[Arg]

    Permalink

    Arguments this parser accepts.

    Arguments this parser accepts.

    Used to generate help / usage messages.

    Definition Classes
    ConsParserParser
  7. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  8. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  9. val default: () ⇒ Option[H]

    Permalink
  10. final def detailedParse(args: Seq[String]): Either[Error, (::[H, T], RemainingArgs)]

    Permalink

    Keeps the remaining args before and after a possible -- separated

    Keeps the remaining args before and after a possible -- separated

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

    Permalink
    Definition Classes
    AnyRef
  12. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  13. def get(d: D): Either[Error, ::[H, T]]

    Permalink

    Get the final result from the final intermediate value.

    Get the final result from the final intermediate value.

    Typically fails if some mandatory arguments were not specified, so are missing in d, preventing building a T out of it.

    returns

    in case of success, a T wrapped in scala.Right; else, an error message, wrapped in caseapp.core.Error and scala.Left

    Definition Classes
    ConsParserParser
  14. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  15. def init: D

    Permalink

    Initial value used to accumulate parsed arguments.

    Initial value used to accumulate parsed arguments.

    Definition Classes
    ConsParserParser
  16. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  17. final def map[U](f: (::[H, T]) ⇒ U): Aux[U, D]

    Permalink
    Definition Classes
    Parser
  18. def mapHead[I](f: (H) ⇒ I): Aux[::[I, T], D]

    Permalink
  19. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  20. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  21. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  22. final def parse(args: Seq[String]): Either[Error, (::[H, T], Seq[String])]

    Permalink
    Definition Classes
    Parser
  23. def step(args: List[String], d: ::[Option[H], (tail)#D]): Either[(Error, List[String]), Option[(D, List[String])]]

    Permalink

    Process the next argument.

    Process the next argument.

    If some arguments were successfully processed (third case in return below), the returned remaining argument sequence must be shorter than the passed args.

    This method doesn't fully process args. It tries just to parse *one* argument (typically one option --foo and its value bar, so two elements from args - it can also be only one element in case of a flag), if possible. If you want to fully process a sequence of arguments, see parse or detailedParse.

    returns

    if no argument were parsed, Right(None); if an error occurred, an error message wrapped in caseapp.core.Error and scala.Left; else the next intermediate value and the remaining arguments wrapped in scala.Some and scala.Right.

    Definition Classes
    ConsParserParser
  24. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  25. val tail: Aux[T, DT]

    Permalink
  26. final def wait(): Unit

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

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

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  29. final def withHelp: Parser[WithHelp[::[H, T]]]

    Permalink

    Creates a Parser accepting help / usage arguments, out of this one.

    Creates a Parser accepting help / usage arguments, out of this one.

    Definition Classes
    Parser

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from Parser[::[H, T]]

Inherited from AnyRef

Inherited from Any

Ungrouped