Packages

class MarkupParser extends AnyRef

Performs a parse operation from text markup to a document tree without a subsequent render operation.

In cases where a render operation should follow immediately, it is more convenient to use a laika.api.Transformer instead which combines a parse and a render operation directly.

Example for parsing Markdown:

val res: Either[ParserError, Document] = MarkupParser
  .of(Markdown)
  .using(GitHubFlavor)
  .build
  .parse("hello *there*)

This is a pure API that does not perform any side-effects. For additional options like File and Stream I/O, templating or parallel processing, use the corresponding builders in the laika-io module.

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. MarkupParser
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new MarkupParser(format: MarkupFormat, config: OperationConfig)

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  6. val config: OperationConfig
  7. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  8. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  9. val fileSuffixes: Set[String]

    The file suffixes this parser will recognize as a supported format.

  10. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  11. val format: MarkupFormat
  12. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  13. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  14. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  15. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  16. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  17. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  18. def parse(input: DocumentInput): Either[ParserError, Document]

    Parses the specified markup input into a document AST structure.

  19. def parse(input: String, path: Path): Either[ParserError, Document]

    Parses the specified markup string into a document AST structure.

    Parses the specified markup string into a document AST structure. The given (virtual) path will be assigned to the result.

  20. def parse(input: String): Either[ParserError, Document]

    Parses the specified markup string into a document AST structure.

  21. def parseUnresolved(input: DocumentInput): Either[ParserError, UnresolvedDocument]

    Returns an unresolved document without applying the default rewrite rules and without resolving the configuration header (if present).

    Returns an unresolved document without applying the default rewrite rules and without resolving the configuration header (if present).

    The default rewrite rules resolve link and image references and rearrange the tree into a hierarchy of sections based on the sequence of header instances found in the document.

    The default configuration resolver allows for variable references in the HOCON header of the document to be resolved against values defined in the base configuration.

    This low-level hook is rarely used by application code.

  22. def parseUnresolved(input: String, path: Path): Either[ParserError, UnresolvedDocument]
  23. def parseUnresolved(input: String): Either[ParserError, UnresolvedDocument]
  24. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  25. def toString(): String
    Definition Classes
    AnyRef → Any
  26. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  27. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  28. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()

Inherited from AnyRef

Inherited from Any

Ungrouped