Interface IMarkdownCommentHelper
public interface IMarkdownCommentHelper
Companion class for AbstractCommentParser to decide significance of whitespace
within a markdown comment,
and to detect code blocks (either by indentation or fenced with
```).-
Method Summary
Modifier and TypeMethodDescriptionstatic IMarkdownCommentHelpercreate(AbstractCommentParser parser) intgetTextStart(int textStart) Retrieve the start of the current text, possibly including significant leading whitespace.booleanisInCode()voidrecordFenceChar(char previous, char next, boolean lineStarted) booleanWhen at the beginning of a comment line, record that a whitespace was seen.voidrecordSlash(int nextIndex) voidvoidvoidCall me when we are past the first element of a line.
-
Method Details
-
recordSlash
void recordSlash(int nextIndex) -
recordFenceChar
void recordFenceChar(char previous, char next, boolean lineStarted) -
recordSignificantLeadingSpace
boolean recordSignificantLeadingSpace()When at the beginning of a comment line, record that a whitespace was seen.- Returns:
trueif this whitespace is significant, i.e., beyond the common indent of all lines of this commonmark comment.
-
recordText
void recordText() -
isInCode
boolean isInCode() -
getTextStart
int getTextStart(int textStart) Retrieve the start of the current text, possibly including significant leading whitespace. -
resetLineStart
void resetLineStart()Call me when we are past the first element of a line. -
resetAtLineEnd
void resetAtLineEnd() -
create
-