Parses input from the start index
Parses input from the start index
the start index
the parse result, which type is T
Returns a Parser that represents repetition (0 or more)
Returns a Parser that represents repetition (1 or more).
Returns a Parser that represents repetition (1 or more). It is same as
(this ~ this.*).map { case hd ~ tl => hd :: tl }
Returns a sequential Parser consists of this
and rhs
.
Returns a sequential Parser consists of this
and rhs
.
Note that the result of rhs
is ignored.
It is same as
for { t <- this _ <- rhs } yield t
Returns a sequential Parser consists of this
and rhs
.
Returns a sequential Parser consists of this
and rhs
.
Note that the result of this
is ignored.
It is same as
for { _ <- this u <- rhs } yield u
Returns a repetition Parser (0 or 1)
It is same as map
It is same as map
This method is same as withErrorMessage()
except for
no message being specified.
Returns a Parser
which only succeeds iff predicate(result)
is true
.
Returns a Parser
which only succeeds iff predicate(result)
is true
.
the error message in that predicate(result)
is false
Returns a parser such that 1.
Returns a parser such that
1. this parses from current position
2. convert the intermediate result of type T
to a parser.
3. the parser parses from the next position and returns the result of type U
Returns a parser that the result is converted from T
to U
Returns a parser that the result is converted from T
to U
the result converter
Returns a repetition Parser (0 or more), which separator is
separator
Returns a repetition Parser (0 or more), which separator is
separator
this parses separator, which result is ignored
Returns a repetition Parser (1 or more), which separator is
separator
Returns a repetition Parser (1 or more), which separator is
separator
this parses separator, which result is ignored
Return the same parser except it replace the failure
message with message
Return the same parser except it replace the failure
message with message
Replace the failure parser with the error parser.
Replace the failure parser with the error parser. It is used to suppress backtracks.
the error message
It is same as filter
It is same as filter
Returns an alternation Parser.
Returns an alternation Parser.
It first trys this
.
It trys rhs
iff this
failed.
the result type of rhs
the alternation
Returns a alternation parser.
Returns a alternation parser. It selects longest match.
Returns an alternation parser.
Returns an alternation parser.
It first trys this
.
It trys <cdde>rhs> iff this
failed and parameters are appropriate catchLabels.
Returns a sequential Parser consists of this
and rhs
.
Returns a sequential Parser consists of this
and rhs
.
This method is same as <<
method.
This method is same as <<
method.
The only difference is operator precedence.
This method is same as >>
method.
This method is same as >>
method.
The only difference is operator precedence.
(Since version ) see corresponding Javadoc for more information.
A Parser is used to parse the input from the outer class instances. It returns the result of type T as the ParseResult.
the result type