Top Description Fields Constructors Methods
com.vladsch.flexmark.ext.toc

public Class SimTocExtension

extends Object
implements ParserExtension, HtmlRendererExtension, FormatterExtension
Class Inheritance
All Implemented Interfaces
com.vladsch.flexmark.formatter.Formatter.FormatterExtension, com.vladsch.flexmark.util.misc.Extension, com.vladsch.flexmark.html.HtmlRenderer.HtmlRendererExtension, com.vladsch.flexmark.parser.Parser.ParserExtension
Imports
com.vladsch.flexmark.ext.toc.internal.SimTocBlockParser, .SimTocNodeFormatter, .SimTocNodeRenderer, .TocOptions, com.vladsch.flexmark.formatter.Formatter, com.vladsch.flexmark.html.HtmlRenderer, com.vladsch.flexmark.html.renderer.AttributablePart, com.vladsch.flexmark.parser.Parser, com.vladsch.flexmark.util.data.DataKey, .MutableDataHolder, .NullableDataKey, org.jetbrains.annotations.NotNull

Extension for tocs

Create it with create() and then configure it on the builders

The parsed [TOC] text is turned into SimTocBlock nodes. Rendered into table of contents based on the headings in the document

Field Summary

Modifier and TypeField and Description
public static final DataKey<Boolean>
public static final DataKey<Boolean>
public static final DataKey<Boolean>
public static final DataKey<String>
public static final DataKey<TocOptions>
public static final DataKey<SimTocGenerateOnFormat>
public static final DataKey<Boolean>
public static final DataKey<Boolean>
public static final DataKey<Boolean>
public static final DataKey<Integer>
public static final DataKey<String>
public static final DataKey<TocOptions.ListType>
public static final NullableDataKey<String>
public static final DataKey<Integer>
public static final AttributablePart
public static final AttributablePart

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public static SimTocExtension
public void
public void
extend(Parser.Builder
parser builder with which to register extensions
parserBuilder
)

Implements com.vladsch.flexmark.parser.Parser.ParserExtension.extend.

This method is called on all extensions so that they can register their custom processors

public void
extend(HtmlRenderer.Builder htmlRendererBuilder, @NotNull String rendererType)

public void
parserOptions(MutableDataHolder
option set that will be used for the builder
options
)

Implements com.vladsch.flexmark.parser.Parser.ParserExtension.parserOptions.

This method is called first on all extensions so that they can adjust the options that must be common to all extensions.

public void
rendererOptions(@NotNull MutableDataHolder
option set that will be used for the builder
options
)

Implements com.vladsch.flexmark.formatter.Formatter.FormatterExtension.rendererOptions.

This method is called first on all extensions so that they can adjust the options.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

AST_INCLUDE_OPTIONSback to summary
public static final DataKey<Boolean> AST_INCLUDE_OPTIONS
BLANK_LINE_SPACERback to summary
public static final DataKey<Boolean> BLANK_LINE_SPACER
CASE_SENSITIVE_TOC_TAGback to summary
public static final DataKey<Boolean> CASE_SENSITIVE_TOC_TAG
DIV_CLASSback to summary
public static final DataKey<String> DIV_CLASS
FORMAT_OPTIONSback to summary
public static final DataKey<TocOptions> FORMAT_OPTIONS
FORMAT_UPDATE_ON_FORMATback to summary
public static final DataKey<SimTocGenerateOnFormat> FORMAT_UPDATE_ON_FORMAT
IS_HTMLback to summary
public static final DataKey<Boolean> IS_HTML
IS_NUMBEREDback to summary
public static final DataKey<Boolean> IS_NUMBERED
IS_TEXT_ONLYback to summary
public static final DataKey<Boolean> IS_TEXT_ONLY
LEVELSback to summary
public static final DataKey<Integer> LEVELS
LIST_CLASSback to summary
public static final DataKey<String> LIST_CLASS
LIST_TYPEback to summary
public static final DataKey<TocOptions.ListType> LIST_TYPE
TITLEback to summary
public static final NullableDataKey<String> TITLE
TITLE_LEVELback to summary
public static final DataKey<Integer> TITLE_LEVEL
TOC_CONTENTback to summary
public static final AttributablePart TOC_CONTENT
TOC_LISTback to summary
public static final AttributablePart TOC_LIST

Constructor Detail

SimTocExtensionback to summary
private SimTocExtension()

Method Detail

createback to summary
public static SimTocExtension create()
extendback to summary
public void extend(Formatter.Builder formatterBuilder)

Implements com.vladsch.flexmark.formatter.Formatter.FormatterExtension.extend.

Annotations
@Override
extendback to summary
public void extend(Parser.Builder parserBuilder)

Implements com.vladsch.flexmark.parser.Parser.ParserExtension.extend.

Doc from com.vladsch.flexmark.parser.Parser.ParserExtension.extend.

This method is called on all extensions so that they can register their custom processors

Parameters
parserBuilder:Parser.Builder

parser builder with which to register extensions

Annotations
@Override
extendback to summary
public void extend(HtmlRenderer.Builder htmlRendererBuilder, @NotNull String rendererType)
Annotations
@Override
parserOptionsback to summary
public void parserOptions(MutableDataHolder options)

Implements com.vladsch.flexmark.parser.Parser.ParserExtension.parserOptions.

Doc from com.vladsch.flexmark.parser.Parser.ParserExtension.parserOptions.

This method is called first on all extensions so that they can adjust the options that must be common to all extensions.

Parameters
options:MutableDataHolder

option set that will be used for the builder

Annotations
@Override
rendererOptionsback to summary
public void rendererOptions(@NotNull MutableDataHolder options)

Implements com.vladsch.flexmark.formatter.Formatter.FormatterExtension.rendererOptions.

Doc from com.vladsch.flexmark.formatter.Formatter.FormatterExtension.rendererOptions.

This method is called first on all extensions so that they can adjust the options.

Parameters
options:@NotNull MutableDataHolder

option set that will be used for the builder

Annotations
@Override