laika.parse.rst

BlockParsers

trait BlockParsers extends parse.BlockParsers with ListParsers with TableParsers with ExplicitBlockParsers

Provides the parsers for all types of block-level elements of reStructuredText. It merges the individual traits that provide implementations for list, tables, etc. and adds the remaining block level parsers that do not fit into any of the subcategories supported by the other traits.

Block parsers are only concerned with splitting the document into (potentially nested) blocks. They are used in the first phase of parsing, while delegating to inline parsers for the 2nd phase.

Self Type
BlockParsers with InlineParsers
Linear Supertypes
Known Subclasses
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. BlockParsers
  2. ExplicitBlockParsers
  3. TableParsers
  4. ListParsers
  5. BlockParsers
  6. MarkupParsers
  7. BaseParsers
  8. RegexParsers
  9. Parsers
  10. AnyRef
  11. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Type Members

  1. class CellBuilder extends AnyRef

    Definition Classes
    TableParsers
  2. class CellBuilderRef extends AnyRef

    Definition Classes
    TableParsers
  3. class ColumnBuilder extends AnyRef

    Definition Classes
    TableParsers
  4. type Elem = Char

    Definition Classes
    RegexParsers → Parsers
  5. case class Error extends NoSuccess with Product with Serializable

    Definition Classes
    Parsers
  6. case class Failure extends NoSuccess with Product with Serializable

    Definition Classes
    Parsers
  7. case class IndentedBlock(nestLevel: Int, minIndent: Int, lines: List[String]) extends Product with Serializable

    Definition Classes
    BlockParsers
  8. type Input = Reader[(BlockParsers.this)#Elem]

    Definition Classes
    Parsers
  9. class MalformedTableException extends RuntimeException

    Definition Classes
    TableParsers
  10. class MarkupParserException extends RuntimeException

    Exception thrown when parsing a text markup document or fragment fails.

  11. class NestedCharSequenceReader extends CharSequenceReader

    Reader implementation that keeps the current nest level in case of recursive parsing of block-level elements.

  12. sealed abstract class NoSuccess extends ParseResult[Nothing]

    Definition Classes
    Parsers
  13. trait OnceParser[+T] extends Parser[T]

    Definition Classes
    Parsers
  14. sealed abstract class ParseResult[+T] extends AnyRef

    Definition Classes
    Parsers
  15. abstract class Parser[+T] extends (Input) ⇒ ParseResult[T]

    Definition Classes
    Parsers
  16. class ParserOps[A] extends AnyRef

    Provides additional combinator methods to parsers via implicit conversion.

  17. class RowBuilder extends AnyRef

    Definition Classes
    TableParsers
  18. case class Success[+T] extends ParseResult[T] with Product with Serializable

    Definition Classes
    Parsers
  19. class TableBuilder extends AnyRef

    Definition Classes
    TableParsers
  20. class TextParser extends Parser[String]

    API for specifying further constraints on the parsers provided by this base trait.

  21. case class ~[+a, +b] extends Product with Serializable

    Definition Classes
    Parsers

Abstract Value Members

  1. abstract def blockDirective(name: String): Option[DirectivePart[Block]]

    Retrieves the block directive with the specified name.

    Retrieves the block directive with the specified name.

    See laika.parse.rst.Directives for details on how to implement directives.

    Definition Classes
    ExplicitBlockParsers
  2. abstract def spanDirective(name: String): Option[DirectivePart[Span]]

    Retrieves the span directive with the specified name.

    Retrieves the span directive with the specified name.

    See laika.parse.rst.Directives for details on how to implement directives.

    Definition Classes
    ExplicitBlockParsers
  3. abstract def textRole(name: String): Option[RoleDirectivePart[(String) ⇒ Span]]

    Retrieves the text role with the specified name.

    Retrieves the text role with the specified name.

    See laika.parse.rst.TextRoles for details on how to implement text roles.

    Definition Classes
    ExplicitBlockParsers

Concrete Value Members

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

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

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

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. object NoSuccess

    Definition Classes
    Parsers
  7. def OnceParser[T](f: ((BlockParsers.this)#Input) ⇒ (BlockParsers.this)#ParseResult[T]): (BlockParsers.this)#Parser[T] with (BlockParsers.this)#OnceParser[T]

    Definition Classes
    Parsers
  8. def Parser[T](f: ((BlockParsers.this)#Input) ⇒ (BlockParsers.this)#ParseResult[T]): (BlockParsers.this)#Parser[T]

    Definition Classes
    Parsers
  9. def accept[U](expected: String, f: PartialFunction[(BlockParsers.this)#Elem, U]): (BlockParsers.this)#Parser[U]

    Definition Classes
    Parsers
  10. def accept[ES](es: ES)(implicit arg0: (ES) ⇒ List[(BlockParsers.this)#Elem]): (BlockParsers.this)#Parser[List[(BlockParsers.this)#Elem]]

    Definition Classes
    Parsers
  11. implicit def accept(e: (BlockParsers.this)#Elem): (BlockParsers.this)#Parser[(BlockParsers.this)#Elem]

    Definition Classes
    Parsers
  12. def acceptIf(p: ((BlockParsers.this)#Elem) ⇒ Boolean)(err: ((BlockParsers.this)#Elem) ⇒ String): (BlockParsers.this)#Parser[(BlockParsers.this)#Elem]

    Definition Classes
    Parsers
  13. def acceptMatch[U](expected: String, f: PartialFunction[(BlockParsers.this)#Elem, U]): (BlockParsers.this)#Parser[U]

    Definition Classes
    Parsers
  14. def acceptSeq[ES](es: ES)(implicit arg0: (ES) ⇒ Iterable[(BlockParsers.this)#Elem]): (BlockParsers.this)#Parser[List[(BlockParsers.this)#Elem]]

    Definition Classes
    Parsers
  15. val any: (BlockParsers.this)#TextParser

    Consumes any kind of input, always succeeds.

    Consumes any kind of input, always succeeds. This parser would consume the entire input unless a max constraint is specified.

    Definition Classes
    MarkupParsers
  16. def anyBut(chars: Char*): (BlockParsers.this)#TextParser

    Consumes any number of consecutive characters that are not one of the specified characters.

    Consumes any number of consecutive characters that are not one of the specified characters. Always succeeds unless a minimum number of required matches is specified.

    Definition Classes
    MarkupParsers
  17. def anyIn(ranges: Traversable[Char]*): (BlockParsers.this)#TextParser

    Consumes any number of consecutive characters that are in one of the specified character ranges.

    Consumes any number of consecutive characters that are in one of the specified character ranges. Always succeeds unless a minimum number of required matches is specified.

    Definition Classes
    MarkupParsers
  18. def anyOf(chars: Char*): (BlockParsers.this)#TextParser

    Consumes any number of consecutive occurrences of the specified characters.

    Consumes any number of consecutive occurrences of the specified characters. Always succeeds unless a minimum number of required matches is specified.

    Definition Classes
    MarkupParsers
  19. def anyUntil(until: ⇒ (BlockParsers.this)#Parser[Any]): (BlockParsers.this)#TextParser

    Consumes any number of characters for which the specified parser fails on the corresponding offset.

    Consumes any number of characters for which the specified parser fails on the corresponding offset. This parser fails if the end of input is reached without the specified parser ever succeeding or if the parser causes an Error result instead of a plain Failure or Success. Further constraints like minimum or maximum number of required matching characters can be specified through the API of the returned TextParser instance.

    Definition Classes
    MarkupParsers
  20. def anyUntil(chars: Char*): (BlockParsers.this)#TextParser

    Consumes any number of consecutive characters that are not one of the specified characters.

    Consumes any number of consecutive characters that are not one of the specified characters.

    This parser is identical to the anyBut parser except for two differences: this parser fails if it reaches the end of the input without seeing any of the specified characters and it also consumes this final character, without adding it to the result. This parser is usually used when a construct like a span enclosed between two characters needs to be parsed.

    Definition Classes
    MarkupParsers
  21. def anyWhile(p: (Char) ⇒ Boolean): (BlockParsers.this)#TextParser

    Consumes any number of consecutive characters which satisfy the specified predicate.

    Consumes any number of consecutive characters which satisfy the specified predicate. Always succeeds unless a minimum number of required matches is specified.

    Definition Classes
    MarkupParsers
  22. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  23. val atStart: (BlockParsers.this)#Parser[(BlockParsers.this)#Parser[Unit]]

    Succeeds at the start of the input.

    Succeeds at the start of the input.

    Definition Classes
    MarkupParsers
  24. val blankLine: (BlockParsers.this)#Parser[String]

    Parses a blank line from the current input offset (which may not be at the start of the line).

    Parses a blank line from the current input offset (which may not be at the start of the line). Fails for lines that contain any non-whitespace character. Does always produce an empty string as the result, discarding any whitespace characters found in the line.

    Since it also succeeds at the end of the input it should never be used in the form of (blankLine *) or (blankLine +). Use the blankLines parser instead in these cases.

    Definition Classes
    BlockParsers
  25. val blankLines: (BlockParsers.this)#Parser[List[String]]

    Parses one or more blanklines, producing a list of empty strings corresponding to the number of blank lines consumed.

    Parses one or more blanklines, producing a list of empty strings corresponding to the number of blank lines consumed.

    Definition Classes
    BlockParsers
  26. def block(firstLinePrefix: (BlockParsers.this)#Parser[Any], linePrefix: ⇒ (BlockParsers.this)#Parser[Any], nextBlockPrefix: ⇒ (BlockParsers.this)#Parser[Any]): (BlockParsers.this)#Parser[List[String]]

    Parses a full block based on the specified helper parsers.

    Parses a full block based on the specified helper parsers.

    firstLinePrefix

    parser that recognizes the start of the first line of this block

    linePrefix

    parser that recognizes the start of subsequent lines that still belong to the same block

    nextBlockPrefix

    parser that recognizes whether a line after one or more blank lines still belongs to the same block

    Definition Classes
    BlockParsers
  27. def blockDirective: (BlockParsers.this)#Parser[Block]

    Parses a block-level directive.

  28. def blockList(parser: ⇒ (BlockParsers.this)#Parser[Block]): (BlockParsers.this)#Parser[List[Block]]

    Builds a parser for a list of blocks based on the parser for a single block.

    Builds a parser for a list of blocks based on the parser for a single block.

    Overridden to add the processing required for cases where a block has influence on the parsing or processing of the subsequent block.

    This includes checking each Paragraph for a double colon ending which turns the following block into a literal block as well as processing internal link targets and section headers.

    parser

    the parser for a single block element

    returns

    a parser for a list of blocks

    Definition Classes
    BlockParsersBlockParsers
  29. def blockQuote: (BlockParsers.this)#Parser[Block]

    Parses a block quote with an optional attribution.

    Parses a block quote with an optional attribution.

    See http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#block-quotes

  30. def bulletList: (BlockParsers.this)#Parser[BulletList]

    Parses a bullet list with any of the supported bullet characters.

    Parses a bullet list with any of the supported bullet characters.

    See http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#bullet-lists.

    Definition Classes
    ListParsers
  31. def chainl1[T, U](first: ⇒ (BlockParsers.this)#Parser[T], p: ⇒ (BlockParsers.this)#Parser[U], q: ⇒ (BlockParsers.this)#Parser[(T, U) ⇒ T]): (BlockParsers.this)#Parser[T]

    Definition Classes
    Parsers
  32. def chainl1[T](p: ⇒ (BlockParsers.this)#Parser[T], q: ⇒ (BlockParsers.this)#Parser[(T, T) ⇒ T]): (BlockParsers.this)#Parser[T]

    Definition Classes
    Parsers
  33. def chainr1[T, U](p: ⇒ (BlockParsers.this)#Parser[T], q: ⇒ (BlockParsers.this)#Parser[(T, U) ⇒ U], combine: (T, U) ⇒ U, first: U): (BlockParsers.this)#Parser[U]

    Definition Classes
    Parsers
  34. implicit def charToTraversalble(char: Char): Traversable[Char]

    Implicit conversion that allows to pass a single character to the range-based anyIn parser.

    Implicit conversion that allows to pass a single character to the range-based anyIn parser.

    Definition Classes
    MarkupParsers
  35. def citation: (BlockParsers.this)#Parser[Citation]

    Parses a citation.

  36. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  37. def comment: (BlockParsers.this)#Parser[Comment]

    Parses a comment.

  38. def commit[T](p: ⇒ (BlockParsers.this)#Parser[T]): (BlockParsers.this)#Parser[T]

    Definition Classes
    Parsers
  39. def config(path: Path): (BlockParsers.this)#Parser[Either[InvalidBlock, Config]]

    Definition Classes
    BlockParsers
  40. def definitionList: (BlockParsers.this)#Parser[Block]

    Parses a definition list.

  41. def doctest: (BlockParsers.this)#Parser[Block]

    Parses a doctest block.

    Parses a doctest block. This is a feature which is very specific to the world of Python where reStructuredText originates. Therefore the resulting DoctestBlock tree element is not part of the standard Laika tree model. When this block type is used the corresponding special renderers must be enabled (e.g. the ExtendedHTML renderer for HTML).

    See http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#doctest-blocks

  42. def elem(e: (BlockParsers.this)#Elem): (BlockParsers.this)#Parser[(BlockParsers.this)#Elem]

    Definition Classes
    Parsers
  43. def elem(kind: String, p: ((BlockParsers.this)#Elem) ⇒ Boolean): (BlockParsers.this)#Parser[(BlockParsers.this)#Elem]

    Definition Classes
    Parsers
  44. def enumList: (BlockParsers.this)#Parser[EnumList]

    Parses an enumerated list in any of the supported combinations of enumeration style and formatting.

    Parses an enumerated list in any of the supported combinations of enumeration style and formatting.

    See http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#enumerated-lists.

    Definition Classes
    ListParsers
  45. def eof: (BlockParsers.this)#Parser[String]

    Succeeds at the end of the input.

    Succeeds at the end of the input.

    Definition Classes
    MarkupParsers
  46. def eol: (BlockParsers.this)#Parser[String]

    Succeeds at the end of a line, including the end of the input.

    Succeeds at the end of a line, including the end of the input. Produces an empty string as a result and consumes any new line characters.

    Definition Classes
    MarkupParsers
  47. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  48. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  49. def err(msg: String): (BlockParsers.this)#Parser[Nothing]

    Definition Classes
    Parsers
  50. def explicitBlockItem: (BlockParsers.this)#Parser[Block]

    Parses all types of explicit block items.

  51. def failure(msg: String): (BlockParsers.this)#Parser[Nothing]

    Definition Classes
    Parsers
  52. def fieldList: (BlockParsers.this)#Parser[Block]

    Parses a field list.

  53. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  54. def footnote: (BlockParsers.this)#Parser[FootnoteDefinition]

    Parses a footnote.

  55. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  56. def gridTable: (BlockParsers.this)#Parser[Table]

    Parses a grid table.

  57. def guard[T](p: ⇒ (BlockParsers.this)#Parser[T]): (BlockParsers.this)#Parser[T]

    Definition Classes
    Parsers
  58. def handleWhiteSpace(source: CharSequence, offset: Int): Int

    Attributes
    protected
    Definition Classes
    RegexParsers
  59. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  60. def headerWithOverline: (BlockParsers.this)#Parser[Block]

    Parses a section header with both overline and underline.

    Parses a section header with both overline and underline.

    See http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#sections.

  61. def headerWithUnderline: (BlockParsers.this)#Parser[Block]

    Parses a section header with an underline, but no overline.

    Parses a section header with an underline, but no overline.

    See http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#sections.

  62. def indentedBlock(minIndent: Int = 1, linePredicate: ⇒ (BlockParsers.this)#Parser[Any] = success(), endsOnBlankLine: Boolean = false, firstLineIndented: Boolean = false, maxIndent: Int = Int.MaxValue): (BlockParsers.this)#Parser[(BlockParsers.this)#IndentedBlock]

    Parses a full block based on the specified helper parsers, expecting an indentation for all lines except the first.

    Parses a full block based on the specified helper parsers, expecting an indentation for all lines except the first. The indentation may vary between the parts of the indented block, so that this parser only cuts off the minimum indentation shared by all lines, but each line must have at least the specified minimum indentation.

    minIndent

    the minimum indentation that each line in this block must have

    linePredicate

    parser that recognizes the start of subsequent lines that still belong to the same block

    endsOnBlankLine

    indicates whether parsing should end on the first blank line

    firstLineIndented

    indicates whether the first line is expected to be indented, too

    maxIndent

    the maximum indentation that will get dropped from the start of each line of the result

    returns

    a parser that produces an instance of IndentedBlock

    Definition Classes
    BlockParsers
  63. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  64. def lineBlock: (BlockParsers.this)#Parser[Block]

    Parses a block of lines with line breaks preserved.

    Parses a block of lines with line breaks preserved.

    See http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#line-blocks.

    Definition Classes
    ListParsers
  65. def linkTarget: (BlockParsers.this)#Parser[Block with Span with Serializable]

    Parses a link definition, either an internal, external or indirect link.

    Parses a link definition, either an internal, external or indirect link.

    See http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#hyperlink-targets.

    Definition Classes
    ExplicitBlockParsers
  66. implicit def literal(s: String): (BlockParsers.this)#Parser[String]

    Definition Classes
    RegexParsers
  67. def literalBlock: (BlockParsers.this)#Parser[Block]

    Parses a literal block, either quoted or indented.

    Parses a literal block, either quoted or indented. Only used when the preceding block ends with a double colon (::).

    See http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#literal-blocks

  68. def log[T](p: ⇒ (BlockParsers.this)#Parser[T])(name: String): (BlockParsers.this)#Parser[T]

    Definition Classes
    Parsers
  69. def lookBehind[T](offset: Int, parser: ⇒ (BlockParsers.this)#Parser[T]): (BlockParsers.this)#Parser[T]

    Applies the specified parser at the specified offset behind the current position.

    Applies the specified parser at the specified offset behind the current position. Never consumes any input.

    Definition Classes
    BaseParsers
  70. val maxNestLevel: Int

    The maximum level of block nesting.

    The maximum level of block nesting. Some block types like lists and blockquotes contain nested blocks. To protect against malicious input or accidentally broken markup, the level of nesting is restricted.

    Definition Classes
    BlockParsers
  71. def mkList[T]: ((BlockParsers.this)#~[T, List[T]]) ⇒ List[T]

    Definition Classes
    Parsers
  72. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  73. def nestLevel(reader: (BlockParsers.this)#Input): Int

    Returns the current nest level from the specified input or 0 if it cannot be determined.

    Returns the current nest level from the specified input or 0 if it cannot be determined.

    The nest level is usually only used to prevent endless recursion of nested blocks.

    Definition Classes
    BlockParsers
  74. final lazy val nestedBlock: (BlockParsers.this)#Parser[Block]

    Parses any kind of nested block supported by a concrete markup language.

    Parses any kind of nested block supported by a concrete markup language.

    Definition Classes
    BlockParsers
  75. def nonRecursiveBlock: (BlockParsers.this)#Parser[Block]

    Parses reStructuredText blocks, except for blocks that allow nesting of blocks.

    Parses reStructuredText blocks, except for blocks that allow nesting of blocks. Only used in rare cases when the maximum nest level allowed had been reached

    Definition Classes
    BlockParsersBlockParsers
  76. def not[T](p: ⇒ (BlockParsers.this)#Parser[T]): (BlockParsers.this)#Parser[Unit]

    Definition Classes
    Parsers
  77. final def notify(): Unit

    Definition Classes
    AnyRef
  78. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  79. def opt[T](p: ⇒ (BlockParsers.this)#Parser[T]): (BlockParsers.this)#Parser[Option[T]]

    Definition Classes
    Parsers
  80. def optimizedCharLookup(chars: Char*): (Char) ⇒ Boolean

    Returns an optimized, Array-based lookup function for the specified characters.

    Returns an optimized, Array-based lookup function for the specified characters.

    Attributes
    protected
    Definition Classes
    MarkupParsers
  81. def optimizedRangeLookup(ranges: Traversable[Char]*): (Char) ⇒ Boolean

    Returns an optimized, Array-based lookup function for the specified ranges of characters.

    Returns an optimized, Array-based lookup function for the specified ranges of characters.

    Attributes
    protected
    Definition Classes
    MarkupParsers
  82. def optionList: (BlockParsers.this)#Parser[Block]

    Parses an option list.

  83. def paragraph: (BlockParsers.this)#Parser[Paragraph]

    Parses a single paragraph.

    Parses a single paragraph. Everything between two blank lines that is not recognized as a special reStructuredText block type will be parsed as a regular paragraph.

  84. def parse[T](p: (BlockParsers.this)#Parser[T], in: Reader): (BlockParsers.this)#ParseResult[T]

    Definition Classes
    RegexParsers
  85. def parse[T](p: (BlockParsers.this)#Parser[T], in: CharSequence): (BlockParsers.this)#ParseResult[T]

    Definition Classes
    RegexParsers
  86. def parse[T](p: (BlockParsers.this)#Parser[T], in: Reader[Char]): (BlockParsers.this)#ParseResult[T]

    Definition Classes
    RegexParsers
  87. def parseAll[T](p: (BlockParsers.this)#Parser[T], in: CharSequence): (BlockParsers.this)#ParseResult[T]

    Definition Classes
    RegexParsers
  88. def parseAll[T](p: (BlockParsers.this)#Parser[T], in: Reader): (BlockParsers.this)#ParseResult[T]

    Definition Classes
    RegexParsers
  89. def parseAll[T](p: (BlockParsers.this)#Parser[T], in: Reader[Char]): (BlockParsers.this)#ParseResult[T]

    Definition Classes
    RegexParsers
  90. def parseConfigAndRoot(reader: Reader[Char], path: Path): (Config, RootElement)

    Fully parses the input from the specified reader and returns the configuration and root element.

    Fully parses the input from the specified reader and returns the configuration and root element.

    Attributes
    protected
    Definition Classes
    BlockParsers
  91. def parseDirectivePart[T](parser: (BlockParsers.this)#Parser[T], source: String): Either[String, T]

    Utility method to be used by custom parsers for directive argument or body.

    Utility method to be used by custom parsers for directive argument or body. It translates a Success into a Right and a NoSuccess into a Left.

    Definition Classes
    ExplicitBlockParsers
  92. def parseDocument(reader: Reader[Char], path: Path): Document

    Fully parses the input from the specified reader and returns the document tree.

    Fully parses the input from the specified reader and returns the document tree. This function is expected to always succeed, errors would be considered a bug of this library, as the parsers treat all unknown or malformed markup as regular text.

    Definition Classes
    BlockParsersBlockParsers
  93. def parseMarkup[T](parser: (BlockParsers.this)#Parser[T], reader: Reader[Char]): T

    Fully parses the input from the specified reader and returns the result.

    Fully parses the input from the specified reader and returns the result. This function is expected to always succeed, errors would be considered a bug in this library, as the parsers treat all unknown or malformed markup as regular text.

    Definition Classes
    MarkupParsers
  94. def parseMarkup[T](parser: (BlockParsers.this)#Parser[T], source: String): T

    Fully parses the specified input string and returns the result.

    Fully parses the specified input string and returns the result. This function is expected to always succeed, errors would be considered a bug in this library, as the parsers treat all unknown or malformed markup as regular text.

    Definition Classes
    MarkupParsers
  95. def parseNestedBlocks(block: (BlockParsers.this)#IndentedBlock): List[Block]

    Parses all nested blocks inside the specified indented block.

    Parses all nested blocks inside the specified indented block.

    Definition Classes
    BlockParsers
  96. def parseNestedBlocks(input: String, nestLevel: Int): List[Block]

    Parses all nested blocks for the specified input and nest level.

    Parses all nested blocks for the specified input and nest level. Delegates to the abstract nestedBlock parser that sub-traits need to define. The nest level is primarily used as a protection against malicious input that forces endless recursion.

    input

    the input to parse

    nestLevel

    the level of nesting with 0 being the outermost level

    returns

    the parser result as a list of blocks

    Definition Classes
    BlockParsers
  97. def parseNestedBlocks(lines: List[String], nestLevel: Int): List[Block]

    Parses all nested blocks for the specified input and nest level.

    Parses all nested blocks for the specified input and nest level. Delegates to the abstract nestedBlock parser that sub-traits need to define. The nest level is primarily used as a protection against malicious input that forces endless recursion.

    lines

    the input to parse

    nestLevel

    the level of nesting with 0 being the outermost level

    returns

    the parser result as a list of blocks

    Definition Classes
    BlockParsers
  98. def phrase[T](p: (BlockParsers.this)#Parser[T]): (BlockParsers.this)#Parser[T]

    Definition Classes
    RegexParsers → Parsers
  99. def positioned[T <: Positional](p: ⇒ (BlockParsers.this)#Parser[T]): (BlockParsers.this)#Parser[T]

    Definition Classes
    RegexParsers → Parsers
  100. def prepareBlockParsers(nested: Boolean): List[(BlockParsers.this)#Parser[Block]]

    Extension hook for assembling the block parsers for a particular markup format.

    Extension hook for assembling the block parsers for a particular markup format.

    nested

    true if these are parsers for nested blocks, false if they are for top level blocks

    returns

    a list of block parsers which later will be interpreted as choices in the specified order

    Attributes
    protected
    Definition Classes
    BlockParsersBlockParsers
  101. val punctuationChar: (BlockParsers.this)#TextParser

    Parses punctuation characters as supported by transitions (rules) and overlines and underlines for header sections.

    Parses punctuation characters as supported by transitions (rules) and overlines and underlines for header sections.

    Definition Classes
    BlockParsersListParsers
  102. implicit def regex(r: Regex): (BlockParsers.this)#Parser[String]

    Definition Classes
    RegexParsers
  103. def rep[T](first: ⇒ (BlockParsers.this)#Parser[T], next: (T) ⇒ (BlockParsers.this)#Parser[T]): (BlockParsers.this)#Parser[List[T]]

    A parser generator for repetitions where all subsequent parsers after the first depend on the result of the previous.

    A parser generator for repetitions where all subsequent parsers after the first depend on the result of the previous.

    first

    the parser to use for the first piece of input

    next

    a function that determines the next parser based on the result of the previous

    Definition Classes
    BaseParsers
  104. def rep[T](p: ⇒ (BlockParsers.this)#Parser[T]): (BlockParsers.this)#Parser[List[T]]

    Definition Classes
    Parsers
  105. def rep1[T](first: ⇒ (BlockParsers.this)#Parser[T], p0: ⇒ (BlockParsers.this)#Parser[T]): (BlockParsers.this)#Parser[List[T]]

    Definition Classes
    Parsers
    Annotations
    @migration
    Migration

    (Changed in version 2.9.0) The p0 call-by-name arguments is evaluated at most once per constructed Parser object, instead of on every need that arises during parsing.

  106. def rep1[T](p: ⇒ (BlockParsers.this)#Parser[T]): (BlockParsers.this)#Parser[List[T]]

    Definition Classes
    Parsers
  107. def rep1sep[T](p: ⇒ (BlockParsers.this)#Parser[T], q: ⇒ (BlockParsers.this)#Parser[Any]): (BlockParsers.this)#Parser[List[T]]

    Definition Classes
    Parsers
  108. def repMax[T](num: Int, p: ⇒ (BlockParsers.this)#Parser[T]): (BlockParsers.this)#Parser[List[T]]

    Uses the parser for at most the specified number of repetitions, always succeeds.

    Uses the parser for at most the specified number of repetitions, always succeeds. The result is the list of results from applying the parser repeatedly.

    Definition Classes
    BaseParsers
  109. def repMin[T](num: Int, p: ⇒ (BlockParsers.this)#Parser[T]): (BlockParsers.this)#Parser[List[T]]

    Uses the parser for at least the specified number of repetitions or otherwise fails.

    Uses the parser for at least the specified number of repetitions or otherwise fails. Continues to apply the parser after the minimum has been reached until if fails. The result is the list of results from applying the parser repeatedly.

    Definition Classes
    BaseParsers
  110. def repN[T](num: Int, p: ⇒ (BlockParsers.this)#Parser[T]): (BlockParsers.this)#Parser[List[T]]

    Definition Classes
    Parsers
  111. def repsep[T](p: ⇒ (BlockParsers.this)#Parser[T], q: ⇒ (BlockParsers.this)#Parser[Any]): (BlockParsers.this)#Parser[List[T]]

    Definition Classes
    Parsers
  112. def restOfLine: (BlockParsers.this)#Parser[String]

    Parses the rest of the line from the current input offset no matter whether it consist of whitespace only or some text.

    Parses the rest of the line from the current input offset no matter whether it consist of whitespace only or some text. Does not include the eol character(s).

    Definition Classes
    BlockParsers
  113. def roleDirective: (BlockParsers.this)#Parser[Block]

    Parses a role directive.

  114. def root: (BlockParsers.this)#Parser[RootElement]

    Parses a full document, delegating most of the work to the topLevelBlock parser.

    Parses a full document, delegating most of the work to the topLevelBlock parser.

    Definition Classes
    BlockParsers
  115. lazy val shortAnonymousLinkTarget: (BlockParsers.this)#Parser[ExternalLinkDefinition]

    Parses the short variant of an anonymous link definition (that starts with instead of .. :)

    Parses the short variant of an anonymous link definition (that starts with instead of .. :)

    See http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#anonymous-hyperlinks.

    Definition Classes
    ExplicitBlockParsers
  116. def simpleTable: (BlockParsers.this)#Parser[Table]

    Parses a simple table.

  117. def skipWhitespace: Boolean

    Definition Classes
    MarkupParsers → RegexParsers
  118. def substitutionDefinition: (BlockParsers.this)#Parser[Block with Serializable]

    Parses a substitution definition.

  119. def success[T](v: T): (BlockParsers.this)#Parser[T]

    Definition Classes
    Parsers
  120. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  121. val textLine: (BlockParsers.this)#Parser[String]

    Parses a single text line from the current input offset (which may not be at the start of the line.

    Parses a single text line from the current input offset (which may not be at the start of the line. Fails for blank lines. Does not include the eol character(s).

    Definition Classes
    BlockParsers
  122. def textRoleElements: List[CustomizedTextRole]

    All the base text roles supported by this parser not including any custom roles specified within document markup.

  123. implicit def toParserOps[A](parser: (BlockParsers.this)#Parser[A]): (BlockParsers.this)#ParserOps[A]

    Definition Classes
    BaseParsers
  124. def toString(): String

    Definition Classes
    AnyRef → Any
  125. final lazy val topLevelBlock: (BlockParsers.this)#Parser[Block]

    Parses any kind of top-level block supported by a concrete markup language.

    Parses any kind of top-level block supported by a concrete markup language.

    Definition Classes
    BlockParsers
  126. val transition: (BlockParsers.this)#Parser[Rule]

    Parses a transition (rule).

  127. final def wait(): Unit

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

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

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  130. val whiteSpace: Regex

    Attributes
    protected
    Definition Classes
    RegexParsers
  131. def withFailureMessage[T](p: ⇒ (BlockParsers.this)#Parser[T], msg: String): (BlockParsers.this)#Parser[T]

    Overrides the failure message to the specified parser.

    Overrides the failure message to the specified parser.

    Definition Classes
    ExplicitBlockParsers
  132. def withNestLevel[T](p: ⇒ (BlockParsers.this)#Parser[T]): (BlockParsers.this)#Parser[(Int, T)]

    Creates a new parser that produces a tuple containing the current nest level as well as the result from the specified parser.

    Creates a new parser that produces a tuple containing the current nest level as well as the result from the specified parser.

    The nest level is usually only used to prevent endless recursion of nested blocks.

    Definition Classes
    BlockParsers
  133. def ws: (BlockParsers.this)#TextParser

    Parses horizontal whitespace (space and tab).

    Parses horizontal whitespace (space and tab). Always succeeds, consuming all whitespace found.

    Definition Classes
    BlockParsersMarkupParsers

Deprecated Value Members

  1. def lastNoSuccess: (BlockParsers.this)#NoSuccess

    Definition Classes
    Parsers
    Annotations
    @deprecated
    Deprecated

    (Since version 2.10.0) lastNoSuccess was not thread-safe and will be removed in 2.11.0

  2. def lastNoSuccess_=(x: (BlockParsers.this)#NoSuccess): Unit

    Definition Classes
    Parsers
    Annotations
    @deprecated
    Deprecated

    (Since version 2.10.0) lastNoSuccess was not thread-safe and will be removed in 2.11.0

Inherited from ExplicitBlockParsers

Inherited from TableParsers

Inherited from ListParsers

Inherited from parse.BlockParsers

Inherited from MarkupParsers

Inherited from BaseParsers

Inherited from RegexParsers

Inherited from Parsers

Inherited from AnyRef

Inherited from Any

Ungrouped