In package com.copperleaf.kudzu.parser

class com.copperleaf.kudzu.parser.BetweenTimesParser

Consume input from its parser between minSize and maxSize number of times.

Predicts true when:

  • there is remaining input
  • its parser predicts true

Parsing stops when:

  • we have parsed maxSize number of times already

Parsing fails when:

  • its parser fails to parse
  • its parser could not parse at least minSize number of times.

Constructors

constructor(minSize: Int, maxSize: Int, parser: Parser, name: String = "")

Consume input from its parser between minSize and maxSize number of times.

Predicts true when:

  • there is remaining input
  • its parser predicts true

Parsing stops when:

  • we have parsed maxSize number of times already

Parsing fails when:

  • its parser fails to parse
  • its parser could not parse at least minSize number of times.

Parameters:
  • minSize: Int
  • maxSize: Int
  • parser: Parser
  • name: String = ""

Methods

fun parse(input: ParserContext): <Node, ParserContext>

Parameters:

Extensions

fun checkNotEmpty(input: ParserContext)

Parameters: