Class AsideBlockParser

java.lang.Object
com.vladsch.flexmark.parser.block.AbstractBlockParser
com.vladsch.flexmark.ext.aside.internal.AsideBlockParser
All Implemented Interfaces:
BlockParser

public class AsideBlockParser extends AbstractBlockParser
  • Field Details

    • MARKER_CHAR

      public static final char MARKER_CHAR
      See Also:
    • block

      private final AsideBlock block
    • allowLeadingSpace

      private final boolean allowLeadingSpace
    • continueToBlankLine

      private final boolean continueToBlankLine
    • ignoreBlankLine

      private final boolean ignoreBlankLine
    • interruptsParagraph

      private final boolean interruptsParagraph
    • interruptsItemParagraph

      private final boolean interruptsItemParagraph
    • withLeadSpacesInterruptsItemParagraph

      private final boolean withLeadSpacesInterruptsItemParagraph
    • lastWasBlankLine

      private int lastWasBlankLine
  • Constructor Details

  • Method Details

    • isContainer

      public boolean isContainer()
      Specified by:
      isContainer in interface BlockParser
      Overrides:
      isContainer in class AbstractBlockParser
      Returns:
      true if the block that is parsed is a container (contains other blocks), or false if it's a leaf.
    • isPropagatingLastBlankLine

      public boolean isPropagatingLastBlankLine(BlockParser lastMatchedBlockParser)
      Description copied from class: AbstractBlockParser
      should be overridden in BlockQuote, FencedCode and ListItem
      Specified by:
      isPropagatingLastBlankLine in interface BlockParser
      Overrides:
      isPropagatingLastBlankLine in class AbstractBlockParser
      Parameters:
      lastMatchedBlockParser - the last matched block parser instance
      Returns:
      true if the blank line should be propagated to parent
    • canContain

      public boolean canContain(ParserState state, BlockParser blockParser, Block block)
      Specified by:
      canContain in interface BlockParser
      Overrides:
      canContain in class AbstractBlockParser
      Parameters:
      state - parser state
      blockParser - block parser
      block - new block being started @return true if this block parser's block can contain the given block type, false if it cannot
    • getBlock

      public AsideBlock getBlock()
      Returns:
      the block parser's block node instance
    • closeBlock

      public void closeBlock(ParserState state)
    • tryContinue

      public BlockContinue tryContinue(ParserState state)
      Description copied from interface: BlockParser
      See if the block parser can continue parsing the current block
      Parameters:
      state - current parsing state
      Returns:
      block continue instance
    • isMarker

      static boolean isMarker(ParserState state, int index, boolean inParagraph, boolean inParagraphListItem, boolean allowLeadingSpace, boolean interruptsParagraph, boolean interruptsItemParagraph, boolean withLeadSpacesInterruptsItemParagraph)
    • endsWithMarker

      static boolean endsWithMarker(BasedSequence line)