MarkdownGrammarDefinition class

Complete grammar and parser definition for Markdown.

Built using modular PetitParser mixins and produces typed MarkdownNode AST representations supporting CommonMark 0.31.2 and GFM extensions.

Constructors

MarkdownGrammarDefinition()

Properties

hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

asciiPunctuation() → Parser<String>
Matches any single ASCII punctuation character.
inherited
atxHeading() → Parser<HeadingNode>
ATX heading (# Heading up to ###### Heading).
inherited
atxHeadingInlines() → Parser<InlineNode>
Content of an ATX heading, stopping before trailing # and newline.
inherited
atxHeadingItem() → Parser<InlineNode>
inherited
Autolink in angle brackets (<http:...> or <email:...>).
inherited
blankLine() → Parser<String>
Matches an empty or blank line ending with a newline.
inherited
blankLines() → Parser<List<String>>
Matches one or more consecutive blank lines.
inherited
block() → Parser<BlockNode>
Choice of all block types ordered by precedence.
inherited
blockItem() → Parser<BlockNode>
A single block preceded by optional blank lines.
inherited
blockquote() → Parser<BlockquoteNode>
Blockquote (> text).
inherited
blockquoteLine() → Parser<String>
inherited
bracketPlainTextRun() → Parser<TextNode>
inherited
build() → Parser<DocumentNode>
Builds the default composite parser starting at start.
inherited
buildFrom<T>(Parser<T> parser) → Parser<T>
Builds a composite parser starting with the specified parser.
inherited
bulletList() → Parser<BulletListNode>
Bullet list (-, *, +).
inherited
bulletListItem() → Parser<ListItemNode>
inherited
codeSpan() → Parser<CodeSpanNode>
Inline code span delimited by single, double, or triple backticks.
inherited
directImage() → Parser<ImageNode>
Direct image (![alt](url "title")).
inherited
Direct link ([text](url "title")).
inherited
document() → Parser<DocumentNode>
The root document consisting of zero or more blocks.
inherited
Email autolink (<name@domain>).
inherited
emphasis() → Parser<EmphasisNode>
Regular emphasis (*italic* or _italic_).
inherited
emphasisAsteriskContent() → Parser<InlineNode>
Content inside *...*.
inherited
emphasisAsteriskItem() → Parser<InlineNode>
inherited
emphasisAsteriskTextRun() → Parser<TextNode>
inherited
emphasisUnderscoreContent() → Parser<InlineNode>
Content inside _..._.
inherited
emphasisUnderscoreItem() → Parser<InlineNode>
inherited
emphasisUnderscoreTextRun() → Parser<TextNode>
inherited
escapedChar() → Parser<String>
Matches an escaped ASCII punctuation character, returning the unescaped character.
inherited
escapedCharNode() → Parser<TextNode>
Escaped character returning a TextNode.
inherited
fencedCodeBlock() → Parser<FencedCodeBlockNode>
Fenced code block (``` or ~~~).
inherited
fencedCodeBlockBacktick() → Parser<FencedCodeBlockNode>
inherited
fencedCodeBlockTilde() → Parser<FencedCodeBlockNode>
inherited
hardLineBreak() → Parser<LineBreakNode>
Hard line break (2 trailing spaces or backslash before newline).
inherited
htmlEntity() → Parser<String>
Matches an HTML entity reference or numeric character reference (e.g. &amp;, &#160;, &#x20;).
inherited
indent() → Parser<String>
Matches 4 spaces or a single horizontal tab representing an indentation.
inherited
indentedCodeBlock() → Parser<IndentedCodeBlockNode>
Indented code block (4 spaces or tab).
inherited
indentedCodeLine() → Parser<String>
inherited
inlineItem() → Parser<InlineNode>
Single inline item choice.
inherited
inlines() → Parser<InlineNode>
Top-level sequence of inline nodes with consecutive text nodes merged.
inherited
lineBreakNode() → Parser<LineBreakNode>
Hard or soft line break node.
inherited
linkDestinationAndTitle() → Parser<(String, String?)>
Destination URL and optional title inside parentheses.
inherited
linkReferenceDefinition() → Parser<LinkReferenceDefinitionNode>
Link reference definition ([label]: url "title").
inherited
linkText() → Parser<InlineNode>
Link text inside brackets.
inherited
linkTextItem() → Parser<InlineNode>
Single item inside link brackets (rejects unescaped ]).
inherited
linkTitle() → Parser<String>
Title part of a link destination.
inherited
linkUrl() → Parser<String>
URL part of a link destination.
inherited
listItemContent() → Parser<ListItemNode>
Content of a list item, including optional GFM task checkbox [ ] or [x].
inherited
listItemInlineItem() → Parser<InlineNode>
inherited
listItemInlines() → Parser<InlineNode>
Inlines for a single list item line, stopping before newline.
inherited
newlineSequence() → Parser<String>
Matches a single newline sequence (\n, \r\n, or \r).
inherited
nonIndentSpace() → Parser<String>
Matches zero to three spaces (non-indent space).
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
orderedList() → Parser<OrderedListNode>
Ordered list (1., 2.).
inherited
orderedListItem() → Parser<(int, ListItemNode)>
inherited
paragraph() → Parser<ParagraphNode>
Standard paragraph of text.
inherited
paragraphInlineItem() → Parser<InlineNode>
inherited
paragraphInlineLine() → Parser<List<InlineNode>>
A single line of inlines within a paragraph.
inherited
paragraphInlines() → Parser<InlineNode>
Inlines within a paragraph, spanning multiple lines until a blank line or block break.
inherited
paragraphInterruptBlock() → Parser
Block constructs that interrupt a paragraph line.
inherited
paragraphLineBreak() → Parser<LineBreakNode>
Line break separating paragraph lines, verifying the next line does not start a block.
inherited
plainTextRun() → Parser<TextNode>
Plain non-special text run.
inherited
rawHtmlInline() → Parser<RawHtmlInlineNode>
Raw inline HTML element.
inherited
singleSpecialChar() → Parser<TextNode>
Fallback for standalone special characters (e.g. isolated * or [).
inherited
softLineBreak() → Parser<LineBreakNode>
Soft line break (simple newline).
inherited
sp() → Parser<String>
Matches optional horizontal whitespace (spaces and tabs).
inherited
spPlus() → Parser<String>
Matches one or more horizontal whitespace characters (spaces and tabs).
inherited
start() → Parser<DocumentNode>
Returns the starting production of this definition.
strikethrough() → Parser<StrikethroughNode>
GFM strikethrough (~~deleted~~).
inherited
strikethroughContent() → Parser<InlineNode>
inherited
strikethroughItem() → Parser<InlineNode>
inherited
strikethroughTextRun() → Parser<TextNode>
inherited
strong() → Parser<StrongNode>
Strong emphasis (**bold** or __bold__).
inherited
strongAsteriskContent() → Parser<InlineNode>
Content inside **...**.
inherited
strongAsteriskItem() → Parser<InlineNode>
inherited
strongAsteriskTextRun() → Parser<TextNode>
inherited
strongUnderscoreContent() → Parser<InlineNode>
Content inside __...__.
inherited
strongUnderscoreItem() → Parser<InlineNode>
inherited
strongUnderscoreTextRun() → Parser<TextNode>
inherited
table() → Parser<TableNode>
GFM Table (| col 1 | col 2 | with delimiter and data rows).
inherited
tableCellContent() → Parser<InlineNode>
inherited
tableCellItem() → Parser<InlineNode>
inherited
tableDataRow() → Parser<TableRowNode>
inherited
tableDelimiterCell() → Parser<TableAlignment>
inherited
tableDelimiterRow() → Parser<List<TableAlignment>>
inherited
tableHeaderRow() → Parser<TableRowNode>
inherited
tableRowCells() → Parser<List<TableCellNode>>
inherited
taskCheckbox() → Parser<bool>
inherited
thematicBreak() → Parser<ThematicBreakNode>
Horizontal rule / thematic break (---, ***, ___).
inherited
toString() → String
A string representation of this object.
inherited
URI autolink (<scheme:...>).
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Properties

defaultParser → Parser<DocumentNode>
Default compiled Markdown document parser.
final