object testParser extends BaseParsers
- Alphabetic
- By Inheritance
- testParser
- BaseParsers
- RegexParsers
- Parsers
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Type Members
- type Elem = Char
- Definition Classes
- RegexParsers → Parsers
- case class Error extends NoSuccess with Product with Serializable
- Definition Classes
- Parsers
- case class Failure extends NoSuccess with Product with Serializable
- Definition Classes
- Parsers
- type Input = Reader[Elem]
- Definition Classes
- Parsers
- sealed abstract class NoSuccess extends ParseResult[Nothing]
- Definition Classes
- Parsers
- trait OnceParser[+T] extends Parser[T]
- Definition Classes
- Parsers
- sealed abstract class ParseResult[+T] extends AnyRef
- Definition Classes
- Parsers
- abstract class Parser[+T] extends (Input) => ParseResult[T]
- Definition Classes
- Parsers
- case class Success[+T] extends ParseResult[T] with Product with Serializable
- Definition Classes
- Parsers
- case class ~[+a, +b] extends Product with Serializable
- Definition Classes
- Parsers
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
- def OnceParser[T](f: (Input) => ParseResult[T]): Parser[T] with OnceParser[T]
- Definition Classes
- Parsers
- def Parser[T](f: (Input) => ParseResult[T]): Parser[T]
- Definition Classes
- Parsers
- def aChar: Parser[String]
- Definition Classes
- BaseParsers
- def accept[U](expected: String, f: PartialFunction[Elem, U]): Parser[U]
- Definition Classes
- Parsers
- def accept[ES](es: ES)(implicit f: (ES) => List[Elem]): Parser[List[Elem]]
- Definition Classes
- Parsers
- implicit def accept(e: Elem): Parser[Elem]
- Definition Classes
- Parsers
- def acceptIf(p: (Elem) => Boolean)(err: (Elem) => String): Parser[Elem]
- Definition Classes
- Parsers
- def acceptMatch[S, T](f: PartialFunction[S, T])(p: Parser[S]): Parser[T]
Succeeds if the given parsers succeeds and the given function is defined at the parse result.
Succeeds if the given parsers succeeds and the given function is defined at the parse result. Returns the result of the method applied to the given parsers result.
- Definition Classes
- BaseParsers
- def acceptMatch[U](expected: String, f: PartialFunction[Elem, U]): Parser[U]
- Definition Classes
- Parsers
- def acceptSeq[ES](es: ES)(implicit f: (ES) => Iterable[Elem]): Parser[List[Elem]]
- Definition Classes
- Parsers
- def any: Parser[String]
Matches exactly one char, no matter which.
Matches exactly one char, no matter which. This differs from "elem" as it returns a string consisting of that char.
- Definition Classes
- BaseParsers
- def apply[T](p: Parser[T], in: String): T
Runs the given parser on the given input.
Runs the given parser on the given input. Expects the parser to succeed and consume all input. Throws an IllegalArgumentException if parsing failed.
- Definition Classes
- BaseParsers
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def chainl1[T, U](first: => Parser[T], p: => Parser[U], q: => Parser[(T, U) => T]): Parser[T]
- Definition Classes
- Parsers
- def chainl1[T](p: => Parser[T], q: => Parser[(T, T) => T]): Parser[T]
- Definition Classes
- Parsers
- def chainr1[T, U](p: => Parser[T], q: => Parser[(T, U) => U], combine: (T, U) => U, first: U): Parser[U]
- Definition Classes
- Parsers
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- def commit[T](p: => Parser[T]): Parser[T]
- Definition Classes
- Parsers
- def elem(e: Elem): Parser[Elem]
- Definition Classes
- Parsers
- def elem(kind: String, p: (Elem) => Boolean): Parser[Elem]
- Definition Classes
- Parsers
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def err(msg: String): Parser[Nothing]
- Definition Classes
- Parsers
- def escapeFastForXml(c: Char): String
Either returns the XML escape sequence for the given char or null.
Either returns the XML escape sequence for the given char or null. This does not return Option[String] on purpose. While Option[String] would be a much cleaner solution, this is actually called so often that it is a noticeable difference if we use Option here.
- Definition Classes
- BaseParsers
- def escapeForXml(c: Char): String
Escapes the given char for XML.
Escapes the given char for XML. Returns Either the necessary XML escape Sequence or the same char in a String.
- Definition Classes
- BaseParsers
- def failure(msg: String): Parser[Nothing]
- Definition Classes
- Parsers
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def guard[T](p: => Parser[T]): Parser[T]
- Definition Classes
- Parsers
- def handleWhiteSpace(source: CharSequence, offset: Int): Int
- Attributes
- protected
- Definition Classes
- RegexParsers
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- implicit def literal(s: String): Parser[String]
- Definition Classes
- RegexParsers
- def log[T](p: => Parser[T])(name: String): Parser[T]
- Definition Classes
- Parsers
- def lookbehind(cs: Set[Char]): Parser[Unit]
Looks if the preceding char was one of the given chars.
Looks if the preceding char was one of the given chars. Never consumes any input.
- Definition Classes
- BaseParsers
- def mkList[T]: (~[T, List[T]]) => List[T]
- Definition Classes
- Parsers
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def nl: Parser[String]
Accepts a unix newline and returns a string containing a single newline.
Accepts a unix newline and returns a string containing a single newline.
- Definition Classes
- BaseParsers
- def not[T](p: => Parser[T]): Parser[Unit]
- Definition Classes
- Parsers
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- def oneOf(lookup: Map[Char, String]): Parser[String]
Matches one of the given char keys in the map.
Matches one of the given char keys in the map. Returns the string value for the matched char in the given map.
- Definition Classes
- BaseParsers
- def oneOf(lookup: Set[Char]): Parser[String]
Matches one of the chars in the given set.
Matches one of the chars in the given set. Returns a string with the matched char.
- Definition Classes
- BaseParsers
- def opt[T](p: => Parser[T]): Parser[Option[T]]
- Definition Classes
- Parsers
- def ows: Parser[String]
accepts zero or more spaces or tabs returns the matched whitespace
accepts zero or more spaces or tabs returns the matched whitespace
- Definition Classes
- BaseParsers
- def parse[T](p: Parser[T], in: Reader): ParseResult[T]
- Definition Classes
- RegexParsers
- def parse[T](p: Parser[T], in: CharSequence): ParseResult[T]
- Definition Classes
- RegexParsers
- def parse[T](p: Parser[T], in: Reader[Char]): ParseResult[T]
- Definition Classes
- RegexParsers
- def parseAll[T](p: Parser[T], in: CharSequence): ParseResult[T]
- Definition Classes
- RegexParsers
- def parseAll[T](p: Parser[T], in: Reader): ParseResult[T]
- Definition Classes
- RegexParsers
- def parseAll[T](p: Parser[T], in: Reader[Char]): ParseResult[T]
- Definition Classes
- RegexParsers
- def phrase[T](p: Parser[T]): Parser[T]
- Definition Classes
- RegexParsers → Parsers
- def positioned[T <: Positional](p: => Parser[T]): Parser[T]
- Definition Classes
- RegexParsers → Parsers
- def range(begin: Char, end: Char): Parser[Char]
Matches one char in the given range, returns the matched char.
Matches one char in the given range, returns the matched char.
- Definition Classes
- BaseParsers
- def ranges(rs: SortedMap[Char, Char]): Parser[Char]
- Definition Classes
- BaseParsers
- implicit def regex(r: Regex): Parser[String]
- Definition Classes
- RegexParsers
- def rep[T](p: => Parser[T]): Parser[List[T]]
- Definition Classes
- Parsers
- def rep1[T](first: => Parser[T], p0: => Parser[T]): Parser[List[T]]
- Definition Classes
- Parsers
- Annotations
- @migration
- Migration
(Changed in version 2.9.0) The
p0call-by-name arguments is evaluated at most once per constructed Parser object, instead of on every need that arises during parsing.
- def rep1[T](p: => Parser[T]): Parser[List[T]]
- Definition Classes
- Parsers
- def rep1sep[T](p: => Parser[T], q: => Parser[Any]): Parser[List[T]]
- Definition Classes
- Parsers
- def repN[T](num: Int, p: => Parser[T]): Parser[List[T]]
- Definition Classes
- Parsers
- def repsep[T](p: => Parser[T], q: => Parser[Any]): Parser[List[T]]
- Definition Classes
- Parsers
- def rest: Parser[String]
Matches everything in the parsed string up to the end.
Matches everything in the parsed string up to the end. Also matches the empty String. Returns the matched String.
- Definition Classes
- BaseParsers
- def runParser(s: String, p: Parser[String], iterations: Int): Unit
- def skipWhitespace: Boolean
Whitespace is sometimes important in markdown parsing, we handle it manually.
Whitespace is sometimes important in markdown parsing, we handle it manually. So this returns false.
- Definition Classes
- BaseParsers → RegexParsers
- def success[T](v: T): Parser[T]
- Definition Classes
- Parsers
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- def verboseString(c: Char): String
Returns a verbose description of a char (printed char & hex code).
Returns a verbose description of a char (printed char & hex code). Used for debugging.
- Definition Classes
- BaseParsers
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- val whiteSpace: Regex
- Attributes
- protected
- Definition Classes
- RegexParsers
- def ws: Parser[String]
accepts one or more spaces or tabs returns the matched whitespace
accepts one or more spaces or tabs returns the matched whitespace
- Definition Classes
- BaseParsers
- def ws2: Parser[String]
- def xmlAttr: Parser[String]
Parses an XML Attribute with simplified value handling like xmlAttrVal.
Parses an XML Attribute with simplified value handling like xmlAttrVal.
- Definition Classes
- BaseParsers
- def xmlAttrVal: Parser[String]
Parses a Simplified xml attribute: everything between quotes ("foo") everything between the quotes is run through the escape handling That way you can omit xml escaping when writing inline XML in markdown.
Parses a Simplified xml attribute: everything between quotes ("foo") everything between the quotes is run through the escape handling That way you can omit xml escaping when writing inline XML in markdown.
- Definition Classes
- BaseParsers
- def xmlEndTag: Parser[String]
Parses closing xml tags.
Parses closing xml tags.
- Definition Classes
- BaseParsers
- def xmlName: Parser[String]
Parses an XML name (tag or attribute name)
Parses an XML name (tag or attribute name)
- Definition Classes
- BaseParsers
- def xmlNameChar: Parser[Char]
Parses an XML name char according to W3C spec except that range #x10000 to #xEFFFF is excluded
Parses an XML name char according to W3C spec except that range #x10000 to #xEFFFF is excluded
- Definition Classes
- BaseParsers
- val xmlNameCharRanges: SortedMap[Char, Char]
- Definition Classes
- BaseParsers
- def xmlNameStartChar: Parser[Char]
Parser for one char that starts an XML name.
Parser for one char that starts an XML name. According to W3C specs except that range #x10000 to #xEFFFF is excluded (cannot be expressed by char literals)
- Definition Classes
- BaseParsers
- val xmlNameStartCharRanges: SortedMap[Char, Char]
- Definition Classes
- BaseParsers
- def xmlStartOrEmptyTag: Parser[String]
Parses an xml start or empty tag, attribute values are escaped.
Parses an xml start or empty tag, attribute values are escaped.
- Definition Classes
- BaseParsers