Package org.commonmark.internal
Class ListItemParser
- java.lang.Object
-
- org.commonmark.parser.block.AbstractBlockParser
-
- org.commonmark.internal.ListItemParser
-
- All Implemented Interfaces:
BlockParser
public class ListItemParser extends AbstractBlockParser
-
-
Field Summary
Fields Modifier and Type Field Description private ListItem
block
private int
contentIndent
Minimum number of columns that the content has to be indented (relative to the containing block) to be part of this list item.private boolean
hadBlankLine
-
Constructor Summary
Constructors Constructor Description ListItemParser(int markerIndent, int contentIndent)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
canContain(Block childBlock)
Block
getBlock()
boolean
isContainer()
Return true if the block that is parsed is a container (contains other blocks), or false if it's a leaf.BlockContinue
tryContinue(ParserState state)
-
Methods inherited from class org.commonmark.parser.block.AbstractBlockParser
addLine, addSourceSpan, canHaveLazyContinuationLines, closeBlock, getDefinitions, parseInlines
-
-
-
-
Field Detail
-
block
private final ListItem block
-
contentIndent
private int contentIndent
Minimum number of columns that the content has to be indented (relative to the containing block) to be part of this list item.
-
hadBlankLine
private boolean hadBlankLine
-
-
Method Detail
-
isContainer
public boolean isContainer()
Description copied from interface:BlockParser
Return true if the block that is parsed is a container (contains other blocks), or false if it's a leaf.- Specified by:
isContainer
in interfaceBlockParser
- Overrides:
isContainer
in classAbstractBlockParser
-
canContain
public boolean canContain(Block childBlock)
- Specified by:
canContain
in interfaceBlockParser
- Overrides:
canContain
in classAbstractBlockParser
-
getBlock
public Block getBlock()
-
tryContinue
public BlockContinue tryContinue(ParserState state)
-
-