public class LightInlineParserImpl extends Object implements LightInlineParser
Modifier and Type | Field and Description |
---|---|
protected com.vladsch.flexmark.util.ast.Node |
block |
protected ArrayList<com.vladsch.flexmark.util.sequence.BasedSequence> |
currentText |
protected com.vladsch.flexmark.util.ast.Document |
document |
protected int |
index |
protected com.vladsch.flexmark.util.sequence.BasedSequence |
input |
protected Parsing |
myParsing |
protected InlineParserOptions |
options |
Constructor and Description |
---|
LightInlineParserImpl(com.vladsch.flexmark.util.data.DataHolder dataOptions) |
Modifier and Type | Method and Description |
---|---|
void |
appendNode(@NotNull com.vladsch.flexmark.util.ast.Node node) |
@NotNull Text |
appendSeparateText(@NotNull com.vladsch.flexmark.util.sequence.BasedSequence text) |
void |
appendText(@NotNull com.vladsch.flexmark.util.sequence.BasedSequence text) |
void |
appendText(@NotNull com.vladsch.flexmark.util.sequence.BasedSequence text,
int beginIndex,
int endIndex) |
boolean |
flushTextNode() |
@NotNull com.vladsch.flexmark.util.ast.Node |
getBlock() |
@NotNull ArrayList<com.vladsch.flexmark.util.sequence.BasedSequence> |
getCurrentText() |
@NotNull com.vladsch.flexmark.util.ast.Document |
getDocument() |
int |
getIndex() |
@NotNull com.vladsch.flexmark.util.sequence.BasedSequence |
getInput() |
@NotNull InlineParserOptions |
getOptions() |
@NotNull Parsing |
getParsing() |
com.vladsch.flexmark.util.sequence.BasedSequence |
match(Pattern re)
If RE matches at current index in the input, advance index and return the match; otherwise return null.
|
Matcher |
matcher(Pattern re)
If RE matches at current index in the input, advance index and return the match; otherwise return null.
|
com.vladsch.flexmark.util.sequence.BasedSequence[] |
matchWithGroups(Pattern re)
If RE matches at current index in the input, advance index and return the match; otherwise return null.
|
void |
moveNodes(@NotNull com.vladsch.flexmark.util.ast.Node fromNode,
@NotNull com.vladsch.flexmark.util.ast.Node toNode) |
boolean |
nonIndentSp()
Parse zero or more non-indent spaces
|
char |
peek() |
char |
peek(int ahead) |
void |
setBlock(@NotNull com.vladsch.flexmark.util.ast.Node block) |
void |
setDocument(@NotNull com.vladsch.flexmark.util.ast.Document document) |
void |
setIndex(int index) |
void |
setInput(com.vladsch.flexmark.util.sequence.BasedSequence input) |
boolean |
sp()
Parse zero or more spaces
|
boolean |
spnl()
Parse zero or more space characters, including at most one newline and zero or more spaces.
|
boolean |
spnlUrl()
Parse zero or more space characters, including at one newline.
|
@Nullable com.vladsch.flexmark.util.sequence.BasedSequence |
toEOL()
Parse to end of line, including EOL
|
protected final InlineParserOptions options
protected final Parsing myParsing
protected com.vladsch.flexmark.util.ast.Node block
protected com.vladsch.flexmark.util.sequence.BasedSequence input
protected int index
protected ArrayList<com.vladsch.flexmark.util.sequence.BasedSequence> currentText
protected com.vladsch.flexmark.util.ast.Document document
public LightInlineParserImpl(com.vladsch.flexmark.util.data.DataHolder dataOptions)
@NotNull public @NotNull ArrayList<com.vladsch.flexmark.util.sequence.BasedSequence> getCurrentText()
getCurrentText
in interface LightInlineParser
@NotNull public @NotNull com.vladsch.flexmark.util.sequence.BasedSequence getInput()
getInput
in interface LightInlineParser
public void setInput(com.vladsch.flexmark.util.sequence.BasedSequence input)
setInput
in interface LightInlineParser
public int getIndex()
getIndex
in interface LightInlineParser
public void setIndex(int index)
setIndex
in interface LightInlineParser
@NotNull public @NotNull com.vladsch.flexmark.util.ast.Document getDocument()
getDocument
in interface LightInlineParser
public void setDocument(@NotNull @NotNull com.vladsch.flexmark.util.ast.Document document)
setDocument
in interface LightInlineParser
@NotNull public @NotNull InlineParserOptions getOptions()
getOptions
in interface LightInlineParser
@NotNull public @NotNull Parsing getParsing()
getParsing
in interface LightInlineParser
@NotNull public @NotNull com.vladsch.flexmark.util.ast.Node getBlock()
getBlock
in interface LightInlineParser
public void setBlock(@NotNull @NotNull com.vladsch.flexmark.util.ast.Node block)
setBlock
in interface LightInlineParser
public void moveNodes(@NotNull @NotNull com.vladsch.flexmark.util.ast.Node fromNode, @NotNull @NotNull com.vladsch.flexmark.util.ast.Node toNode)
moveNodes
in interface LightInlineParser
public void appendText(@NotNull @NotNull com.vladsch.flexmark.util.sequence.BasedSequence text)
appendText
in interface LightInlineParser
public void appendText(@NotNull @NotNull com.vladsch.flexmark.util.sequence.BasedSequence text, int beginIndex, int endIndex)
appendText
in interface LightInlineParser
public void appendNode(@NotNull @NotNull com.vladsch.flexmark.util.ast.Node node)
appendNode
in interface LightInlineParser
@NotNull public @NotNull Text appendSeparateText(@NotNull @NotNull com.vladsch.flexmark.util.sequence.BasedSequence text)
appendSeparateText
in interface LightInlineParser
public boolean flushTextNode()
flushTextNode
in interface LightInlineParser
public com.vladsch.flexmark.util.sequence.BasedSequence match(Pattern re)
match
in interface LightInlineParser
re
- pattern to matchpublic com.vladsch.flexmark.util.sequence.BasedSequence[] matchWithGroups(Pattern re)
matchWithGroups
in interface LightInlineParser
re
- pattern to matchpublic Matcher matcher(Pattern re)
matcher
in interface LightInlineParser
re
- pattern to matchpublic char peek()
peek
in interface LightInlineParser
'\0'
in case there are no more characters.public char peek(int ahead)
peek
in interface LightInlineParser
public boolean spnl()
spnl
in interface LightInlineParser
public boolean nonIndentSp()
nonIndentSp
in interface LightInlineParser
public boolean sp()
sp
in interface LightInlineParser
public boolean spnlUrl()
spnlUrl
in interface LightInlineParser
@Nullable public @Nullable com.vladsch.flexmark.util.sequence.BasedSequence toEOL()
toEOL
in interface LightInlineParser
Copyright © 2020. All rights reserved.