Top Description Fields Constructors Methods
com.vladsch.flexmark.ext.gfm.tasklist

public Class TaskListExtension

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.gfm.tasklist.internal.TaskListItemBlockPreProcessor, .TaskListNodeFormatter, .TaskListNodeRenderer, com.vladsch.flexmark.formatter.Formatter, com.vladsch.flexmark.html.HtmlRenderer, com.vladsch.flexmark.parser.ListOptions, .Parser, com.vladsch.flexmark.util.data.DataKey, .MutableDataHolder, org.jetbrains.annotations.NotNull, java.util.HashMap, .Map

Extension for GFM style task list items

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

The bullet list items that begin with [ ], [x] or [X] are turned into TaskListItem nodes

Field Summary

Modifier and TypeField and Description
public static final Map<Character, Integer>
public static final DataKey<Integer>
public static final DataKey<TaskListItemCase>
public static final DataKey<TaskListItemPlacement>
public static final DataKey<Integer>
public static final DataKey<Boolean>
public static final DataKey<Map<Character, Integer>>
FORMAT_TASK_ITEM_PRIORITIES

Priorities corresponding to Parser#LISTS_ITEM_PREFIX_CHARS If shorter than item prefix chars then any missing priorities are set to 0

public static final DataKey<String>
public static final DataKey<String>
public static final DataKey<String>
public static final DataKey<String>
public static final DataKey<String>
public static final DataKey<String>
public static final DataKey<String>

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public static TaskListExtension
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

DEFAULT_PRIORITIESback to summary
public static final Map<Character, Integer> DEFAULT_PRIORITIES
FORMAT_DEFAULT_TASK_ITEM_PRIORITYback to summary
public static final DataKey<Integer> FORMAT_DEFAULT_TASK_ITEM_PRIORITY
FORMAT_LIST_ITEM_CASEback to summary
public static final DataKey<TaskListItemCase> FORMAT_LIST_ITEM_CASE
FORMAT_LIST_ITEM_PLACEMENTback to summary
public static final DataKey<TaskListItemPlacement> FORMAT_LIST_ITEM_PLACEMENT
FORMAT_ORDERED_TASK_ITEM_PRIORITYback to summary
public static final DataKey<Integer> FORMAT_ORDERED_TASK_ITEM_PRIORITY
FORMAT_PRIORITIZED_TASK_ITEMSback to summary
public static final DataKey<Boolean> FORMAT_PRIORITIZED_TASK_ITEMS
FORMAT_TASK_ITEM_PRIORITIESback to summary
public static final DataKey<Map<Character, Integer>> FORMAT_TASK_ITEM_PRIORITIES

Priorities corresponding to Parser#LISTS_ITEM_PREFIX_CHARS If shorter than item prefix chars then any missing priorities are set to 0

ITEM_DONE_CLASSback to summary
public static final DataKey<String> ITEM_DONE_CLASS
ITEM_DONE_MARKERback to summary
public static final DataKey<String> ITEM_DONE_MARKER
ITEM_NOT_DONE_CLASSback to summary
public static final DataKey<String> ITEM_NOT_DONE_CLASS
ITEM_NOT_DONE_MARKERback to summary
public static final DataKey<String> ITEM_NOT_DONE_MARKER
LOOSE_ITEM_CLASSback to summary
public static final DataKey<String> LOOSE_ITEM_CLASS
PARAGRAPH_CLASSback to summary
public static final DataKey<String> PARAGRAPH_CLASS
TIGHT_ITEM_CLASSback to summary
public static final DataKey<String> TIGHT_ITEM_CLASS

Constructor Detail

TaskListExtensionback to summary
private TaskListExtension()

Method Detail

createback to summary
public static TaskListExtension 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