MarkdownListToCollection
class MarkdownListToCollection<T : OutputValue<*>>(list: ListBlock, inlineValueMapper: (Node) -> T, nestedValueMapper: (ListBlock) -> T) : MarkdownListToValue<IterableValue<T>, T, Node>
Helper that converts a Markdown list to an OrderedCollectionValue.
Parameters
list
list to convert
inlineValueMapper
function that maps the node of a list item a value.
nestedValueMapper
function that maps a nested list to a value. This is invoked when the entry is in any of these formats:
Extended:
- :
- value
Content copied to clipboard
(Note that the :
character is not mandatory. Any string is valid since it's ignored by the parsing. :
is the preferred one.)
Compact:
- - value
Content copied to clipboard
T
type of values in the list