PostRenderer

interface PostRenderer

Strategy used to run the post-rendering stage: the rendered content from the rendering stage is wrapped in the document structure offered by the post-renderer. Additionally, the post-renderer provides the output resources that can be saved to file.

Properties

Link copied to clipboard

Rules that determine the default behavior of the media storage. For example, HTML requires local media to be accessible from the file system, hence it's preferred to copy local media to the output directory; it's not necessary to store remote media locally. On the other hand, for example, LaTeX rendering (not yet supported) would require all media to be stored locally, as it does not support remote media.

Functions

Link copied to clipboard

Generates the required output resources. Resources are abstractions of files that are generated during the rendering process and that can be saved on disk.

Link copied to clipboard
abstract fun wrap(content: CharSequence): CharSequence

Wraps rendered content in the full document structure for this rendering strategy. For example, an HTML post-renderer wraps content in <html><head>...</head><body>...</body></html>.

Link copied to clipboard
abstract fun wrapResources(name: String, resources: Set<OutputResource>): OutputResource?

Given the output resources produced by generateResources, merges them into a single resource which complies with com.quarkdown.core.pipeline.Pipeline.execute's output type.