ParserBuilder

laika.api.builder.ParserBuilder
class ParserBuilder(format: MarkupFormat, val config: OperationConfig) extends ParserBuilderOps

Builder API for Parser instances.

Allows to add ExtensionBundles and the strict and withRawContent flags.

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any

Members list

Type members

Types

The type of the operation being configured by this instance.

The type of the operation being configured by this instance.

Attributes

Value members

Concrete methods

Applies all configuration specified with this builder and returns a new MarkupParser instance.

Applies all configuration specified with this builder and returns a new MarkupParser instance.

Attributes

Returns a new instance with the specified configuration.

Returns a new instance with the specified configuration.

This method discards any previously specified options. It is usually meant to be used when copying over the configuration from a fully configured object to an unconfigured one.

Attributes

Inherited methods

Specifies the filter to apply to runtime messages that should cause a transformation to fail.

Specifies the filter to apply to runtime messages that should cause a transformation to fail.

The default is to fail transformations on messages of level Error or higher.

Attributes

Inherited from:
ParserBuilderOps

Turns strict mode on for the target parser, switching off any features not part of the original markup syntax. This includes the registration of markup directives (custom tags) as well as configuration sections at the start of the document.

Turns strict mode on for the target parser, switching off any features not part of the original markup syntax. This includes the registration of markup directives (custom tags) as well as configuration sections at the start of the document.

Attributes

Inherited from:
ParserBuilderOps
def using(bundles: ExtensionBundle*): ThisType

Returns a new instance with the specified extension bundles installed. Features in the new bundles may override features in already installed bundles.

Returns a new instance with the specified extension bundles installed. Features in the new bundles may override features in already installed bundles.

Bundles are usually provided by libraries (by Laika itself or a 3rd-party extension library) or as re-usable building blocks by application code.

Attributes

Inherited from:
CommonBuilderOps
def withConfigValue[T : ConfigEncoder](key: Key, value: T): ThisType

Returns a new instance with the specified configuration value added.

Returns a new instance with the specified configuration value added.

The specified value with have higher precedence than any value with the same key registered by extension bundles, but lower precedence than any value with the same key specified in a configuration file for a directory or a configuration header in a markup document.

Attributes

Inherited from:
ParserBuilderOps
def withConfigValue[T : ConfigEncoder](key: String, value: T): ThisType

Returns a new instance with the specified configuration value added.

Returns a new instance with the specified configuration value added.

The specified value with have higher precedence than any value with the same key registered by extension bundles, but lower precedence than any value with the same key specified in a configuration file for a directory or a configuration header in a markup document.

Attributes

Inherited from:
ParserBuilderOps
def withConfigValue[T : DefaultKey](value: T): ThisType

Returns a new instance with the specified configuration value added.

Returns a new instance with the specified configuration value added.

The specified value with have higher precedence than any value with the same key registered by extension bundles, but lower precedence than any value with the same key specified in a configuration file for a directory or a configuration header in a markup document.

Attributes

Inherited from:
ParserBuilderOps

Enables all extensions that process raw content embedded into the host markup language. These are disabled by default as Laika is designed to render to multiple output formats from a single input document. With raw content embedded the markup document is tied to a specific output format.

Enables all extensions that process raw content embedded into the host markup language. These are disabled by default as Laika is designed to render to multiple output formats from a single input document. With raw content embedded the markup document is tied to a specific output format.

Attributes

Inherited from:
ParserBuilderOps

Concrete fields

The current configuration for this instance.

The current configuration for this instance.

Attributes