use of com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.TextContext in project checkstyle by checkstyle.
the class ParseTreeBuilder method treeLeadingAsterisks.
public static ParseTree treeLeadingAsterisks() {
JavadocContext javadocContext0 = new JavadocContext(null, 0);
CommonToken newline0 = new CommonToken(JavadocTokenTypes.NEWLINE, LINE_SEPARATOR);
javadocContext0.addChild(newline0);
CommonToken leadingAsterisk0 = new CommonToken(JavadocTokenTypes.LEADING_ASTERISK, " *");
javadocContext0.addChild(leadingAsterisk0);
TextContext textContext0 = new TextContext(javadocContext0, 0);
CommonToken ws0 = new CommonToken(JavadocTokenTypes.WS, " ");
textContext0.addChild(ws0);
CommonToken char0 = new CommonToken(JavadocTokenTypes.CHAR, "L");
textContext0.addChild(char0);
CommonToken char1 = new CommonToken(JavadocTokenTypes.CHAR, "e");
textContext0.addChild(char1);
CommonToken char2 = new CommonToken(JavadocTokenTypes.CHAR, "a");
textContext0.addChild(char2);
CommonToken char3 = new CommonToken(JavadocTokenTypes.CHAR, "d");
textContext0.addChild(char3);
CommonToken char4 = new CommonToken(JavadocTokenTypes.CHAR, "i");
textContext0.addChild(char4);
CommonToken char5 = new CommonToken(JavadocTokenTypes.CHAR, "n");
textContext0.addChild(char5);
CommonToken char6 = new CommonToken(JavadocTokenTypes.CHAR, "g");
textContext0.addChild(char6);
CommonToken ws1 = new CommonToken(JavadocTokenTypes.WS, " ");
textContext0.addChild(ws1);
CommonToken char7 = new CommonToken(JavadocTokenTypes.CHAR, "a");
textContext0.addChild(char7);
CommonToken char8 = new CommonToken(JavadocTokenTypes.CHAR, "s");
textContext0.addChild(char8);
CommonToken char9 = new CommonToken(JavadocTokenTypes.CHAR, "t");
textContext0.addChild(char9);
CommonToken char10 = new CommonToken(JavadocTokenTypes.CHAR, "e");
textContext0.addChild(char10);
CommonToken char11 = new CommonToken(JavadocTokenTypes.CHAR, "r");
textContext0.addChild(char11);
CommonToken char12 = new CommonToken(JavadocTokenTypes.CHAR, "i");
textContext0.addChild(char12);
CommonToken char13 = new CommonToken(JavadocTokenTypes.CHAR, "s");
textContext0.addChild(char13);
CommonToken char14 = new CommonToken(JavadocTokenTypes.CHAR, "k");
textContext0.addChild(char14);
javadocContext0.addChild(textContext0);
CommonToken newline1 = new CommonToken(JavadocTokenTypes.NEWLINE, LINE_SEPARATOR);
javadocContext0.addChild(newline1);
CommonToken leadingAsterisk1 = new CommonToken(JavadocTokenTypes.LEADING_ASTERISK, " *");
javadocContext0.addChild(leadingAsterisk1);
TextContext textContext1 = new TextContext(javadocContext0, 0);
CommonToken ws2 = new CommonToken(JavadocTokenTypes.WS, " ");
textContext1.addChild(ws2);
CommonToken char15 = new CommonToken(JavadocTokenTypes.CHAR, "A");
textContext1.addChild(char15);
CommonToken char16 = new CommonToken(JavadocTokenTypes.CHAR, "n");
textContext1.addChild(char16);
CommonToken char17 = new CommonToken(JavadocTokenTypes.CHAR, "o");
textContext1.addChild(char17);
CommonToken char18 = new CommonToken(JavadocTokenTypes.CHAR, "t");
textContext1.addChild(char18);
CommonToken char19 = new CommonToken(JavadocTokenTypes.CHAR, "h");
textContext1.addChild(char19);
CommonToken char20 = new CommonToken(JavadocTokenTypes.CHAR, "e");
textContext1.addChild(char20);
CommonToken char21 = new CommonToken(JavadocTokenTypes.CHAR, "r");
textContext1.addChild(char21);
CommonToken ws3 = new CommonToken(JavadocTokenTypes.WS, " ");
textContext1.addChild(ws3);
CommonToken char22 = new CommonToken(JavadocTokenTypes.CHAR, "o");
textContext1.addChild(char22);
CommonToken char23 = new CommonToken(JavadocTokenTypes.CHAR, "n");
textContext1.addChild(char23);
CommonToken char24 = new CommonToken(JavadocTokenTypes.CHAR, "e");
textContext1.addChild(char24);
javadocContext0.addChild(textContext1);
CommonToken eof0 = new CommonToken(JavadocTokenTypes.EOF, "<EOF>");
javadocContext0.addChild(eof0);
return javadocContext0;
}
use of com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.TextContext in project checkstyle by checkstyle.
the class ParseTreeBuilder method treeOneSimpleHtmlTag.
public static ParseTree treeOneSimpleHtmlTag() {
JavadocContext javadocContext0 = new JavadocContext(null, 0);
HtmlElementContext htmlElementContext0 = new HtmlElementContext(javadocContext0, 0);
HtmlTagContext htmlTagContext0 = new HtmlTagContext(htmlElementContext0, 0);
HtmlElementOpenContext htmlElementOpenContext0 = new HtmlElementOpenContext(htmlTagContext0, 0);
CommonToken open0 = new CommonToken(JavadocTokenTypes.OPEN, "<");
htmlElementOpenContext0.addChild(open0);
CommonToken htmlTagName0 = new CommonToken(JavadocTokenTypes.HTML_TAG_NAME, "g");
htmlElementOpenContext0.addChild(htmlTagName0);
CommonToken close0 = new CommonToken(JavadocTokenTypes.CLOSE, ">");
htmlElementOpenContext0.addChild(close0);
htmlTagContext0.addChild(htmlElementOpenContext0);
TextContext textContext0 = new TextContext(htmlTagContext0, 0);
CommonToken char0 = new CommonToken(JavadocTokenTypes.CHAR, "b");
textContext0.addChild(char0);
CommonToken char1 = new CommonToken(JavadocTokenTypes.CHAR, "l");
textContext0.addChild(char1);
CommonToken char2 = new CommonToken(JavadocTokenTypes.CHAR, "a");
textContext0.addChild(char2);
CommonToken char3 = new CommonToken(JavadocTokenTypes.CHAR, "b");
textContext0.addChild(char3);
CommonToken char4 = new CommonToken(JavadocTokenTypes.CHAR, "l");
textContext0.addChild(char4);
CommonToken char5 = new CommonToken(JavadocTokenTypes.CHAR, "a");
textContext0.addChild(char5);
htmlTagContext0.addChild(textContext0);
HtmlElementCloseContext htmlElementCloseContext0 = new HtmlElementCloseContext(htmlTagContext0, 0);
CommonToken open1 = new CommonToken(JavadocTokenTypes.OPEN, "<");
htmlElementCloseContext0.addChild(open1);
CommonToken slash0 = new CommonToken(JavadocTokenTypes.SLASH, "/");
htmlElementCloseContext0.addChild(slash0);
CommonToken htmlTagName1 = new CommonToken(JavadocTokenTypes.HTML_TAG_NAME, "g");
htmlElementCloseContext0.addChild(htmlTagName1);
CommonToken close1 = new CommonToken(JavadocTokenTypes.CLOSE, ">");
htmlElementCloseContext0.addChild(close1);
htmlTagContext0.addChild(htmlElementCloseContext0);
htmlElementContext0.addChild(htmlTagContext0);
javadocContext0.addChild(htmlElementContext0);
CommonToken eof0 = new CommonToken(JavadocTokenTypes.EOF, "<EOF>");
javadocContext0.addChild(eof0);
return javadocContext0;
}
use of com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.TextContext in project checkstyle by checkstyle.
the class ParseTreeBuilder method treeParamWithGeneric.
public static ParseTree treeParamWithGeneric() {
JavadocContext javadocContext0 = new JavadocContext(null, 0);
JavadocTagContext javadocTagContext0 = new JavadocTagContext(javadocContext0, 0);
CommonToken paramLiteral0 = new CommonToken(JavadocTokenTypes.PARAM_LITERAL, "@param");
javadocTagContext0.addChild(paramLiteral0);
CommonToken ws0 = new CommonToken(JavadocTokenTypes.WS, " ");
javadocTagContext0.addChild(ws0);
CommonToken parameterName0 = new CommonToken(JavadocTokenTypes.PARAMETER_NAME, "<E>");
javadocTagContext0.addChild(parameterName0);
CommonToken ws1 = new CommonToken(JavadocTokenTypes.WS, " ");
javadocTagContext0.addChild(ws1);
DescriptionContext descriptionContext0 = new DescriptionContext(javadocTagContext0, 0);
TextContext textContext0 = new TextContext(descriptionContext0, 0);
CommonToken char0 = new CommonToken(JavadocTokenTypes.CHAR, "m");
textContext0.addChild(char0);
CommonToken char1 = new CommonToken(JavadocTokenTypes.CHAR, "y");
textContext0.addChild(char1);
CommonToken ws2 = new CommonToken(JavadocTokenTypes.WS, " ");
textContext0.addChild(ws2);
CommonToken char2 = new CommonToken(JavadocTokenTypes.CHAR, "f");
textContext0.addChild(char2);
CommonToken char3 = new CommonToken(JavadocTokenTypes.CHAR, "a");
textContext0.addChild(char3);
CommonToken char4 = new CommonToken(JavadocTokenTypes.CHAR, "v");
textContext0.addChild(char4);
CommonToken char5 = new CommonToken(JavadocTokenTypes.CHAR, "o");
textContext0.addChild(char5);
CommonToken char6 = new CommonToken(JavadocTokenTypes.CHAR, "r");
textContext0.addChild(char6);
CommonToken char7 = new CommonToken(JavadocTokenTypes.CHAR, "i");
textContext0.addChild(char7);
CommonToken char8 = new CommonToken(JavadocTokenTypes.CHAR, "t");
textContext0.addChild(char8);
CommonToken char9 = new CommonToken(JavadocTokenTypes.CHAR, "e");
textContext0.addChild(char9);
CommonToken ws3 = new CommonToken(JavadocTokenTypes.WS, " ");
textContext0.addChild(ws3);
CommonToken char10 = new CommonToken(JavadocTokenTypes.CHAR, "t");
textContext0.addChild(char10);
CommonToken char11 = new CommonToken(JavadocTokenTypes.CHAR, "y");
textContext0.addChild(char11);
CommonToken char12 = new CommonToken(JavadocTokenTypes.CHAR, "p");
textContext0.addChild(char12);
CommonToken char13 = new CommonToken(JavadocTokenTypes.CHAR, "e");
textContext0.addChild(char13);
descriptionContext0.addChild(textContext0);
javadocTagContext0.addChild(descriptionContext0);
javadocContext0.addChild(javadocTagContext0);
CommonToken eof0 = new CommonToken(JavadocTokenTypes.EOF, "<EOF>");
javadocContext0.addChild(eof0);
return javadocContext0;
}
use of com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.TextContext in project checkstyle by checkstyle.
the class ParseTreeBuilder method treeNegativeNumberInAttribute.
public static ParseTree treeNegativeNumberInAttribute() {
JavadocContext javadocContext0 = new JavadocContext(null, 0);
HtmlElementContext htmlElementContext0 = new HtmlElementContext(javadocContext0, 0);
HtmlTagContext htmlTagContext0 = new HtmlTagContext(htmlElementContext0, 0);
HtmlElementOpenContext htmlElementOpenContext0 = new HtmlElementOpenContext(htmlTagContext0, 0);
CommonToken open0 = new CommonToken(JavadocTokenTypes.OPEN, "<");
htmlElementOpenContext0.addChild(open0);
CommonToken htmlTagName0 = new CommonToken(JavadocTokenTypes.HTML_TAG_NAME, "font");
htmlElementOpenContext0.addChild(htmlTagName0);
CommonToken ws0 = new CommonToken(JavadocTokenTypes.WS, " ");
htmlElementOpenContext0.addChild(ws0);
AttributeContext attributeContext0 = new AttributeContext(htmlElementOpenContext0, 0);
CommonToken htmlTagName1 = new CommonToken(JavadocTokenTypes.HTML_TAG_NAME, "size");
attributeContext0.addChild(htmlTagName1);
CommonToken equals0 = new CommonToken(JavadocTokenTypes.EQUALS, "=");
attributeContext0.addChild(equals0);
CommonToken attrValue0 = new CommonToken(JavadocTokenTypes.ATTR_VALUE, "-2");
attributeContext0.addChild(attrValue0);
htmlElementOpenContext0.addChild(attributeContext0);
CommonToken close0 = new CommonToken(JavadocTokenTypes.CLOSE, ">");
htmlElementOpenContext0.addChild(close0);
htmlTagContext0.addChild(htmlElementOpenContext0);
TextContext textContext0 = new TextContext(htmlTagContext0, 0);
CommonToken char0 = new CommonToken(JavadocTokenTypes.CHAR, "T");
textContext0.addChild(char0);
CommonToken char1 = new CommonToken(JavadocTokenTypes.CHAR, "M");
textContext0.addChild(char1);
htmlTagContext0.addChild(textContext0);
HtmlElementCloseContext htmlElementCloseContext0 = new HtmlElementCloseContext(htmlTagContext0, 0);
CommonToken open1 = new CommonToken(JavadocTokenTypes.OPEN, "<");
htmlElementCloseContext0.addChild(open1);
CommonToken slash0 = new CommonToken(JavadocTokenTypes.SLASH, "/");
htmlElementCloseContext0.addChild(slash0);
CommonToken htmlTagName2 = new CommonToken(JavadocTokenTypes.HTML_TAG_NAME, "font");
htmlElementCloseContext0.addChild(htmlTagName2);
CommonToken close1 = new CommonToken(JavadocTokenTypes.CLOSE, ">");
htmlElementCloseContext0.addChild(close1);
htmlTagContext0.addChild(htmlElementCloseContext0);
htmlElementContext0.addChild(htmlTagContext0);
javadocContext0.addChild(htmlElementContext0);
CommonToken eof0 = new CommonToken(JavadocTokenTypes.EOF, "<EOF>");
javadocContext0.addChild(eof0);
return javadocContext0;
}
use of com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.TextContext in project checkstyle by checkstyle.
the class ParseTreeBuilder method treeLinkInlineTags.
public static ParseTree treeLinkInlineTags() {
JavadocContext javadocContext0 = new JavadocContext(null, 0);
JavadocInlineTagContext javadocInlineTagContext0 = new JavadocInlineTagContext(javadocContext0, 0);
CommonToken javadocInlineTagStart0 = new CommonToken(JavadocTokenTypes.JAVADOC_INLINE_TAG_START, "{");
javadocInlineTagContext0.addChild(javadocInlineTagStart0);
CommonToken linkLiteral0 = new CommonToken(JavadocTokenTypes.LINK_LITERAL, "@link");
javadocInlineTagContext0.addChild(linkLiteral0);
CommonToken ws0 = new CommonToken(JavadocTokenTypes.WS, " ");
javadocInlineTagContext0.addChild(ws0);
ReferenceContext referenceContext0 = new ReferenceContext(javadocInlineTagContext0, 0);
CommonToken package0 = new CommonToken(JavadocTokenTypes.PACKAGE, "java.lang");
referenceContext0.addChild(package0);
CommonToken dot0 = new CommonToken(JavadocTokenTypes.DOT, ".");
referenceContext0.addChild(dot0);
CommonToken class0 = new CommonToken(JavadocTokenTypes.CLASS, "Integer");
referenceContext0.addChild(class0);
CommonToken hash0 = new CommonToken(JavadocTokenTypes.HASH, "#");
referenceContext0.addChild(hash0);
CommonToken member0 = new CommonToken(JavadocTokenTypes.MEMBER, "valueOf");
referenceContext0.addChild(member0);
javadocInlineTagContext0.addChild(referenceContext0);
CommonToken javadocInlineTagEnd0 = new CommonToken(JavadocTokenTypes.JAVADOC_INLINE_TAG_END, "}");
javadocInlineTagContext0.addChild(javadocInlineTagEnd0);
javadocContext0.addChild(javadocInlineTagContext0);
CommonToken newline0 = new CommonToken(JavadocTokenTypes.NEWLINE, LINE_SEPARATOR);
javadocContext0.addChild(newline0);
JavadocInlineTagContext javadocInlineTagContext1 = new JavadocInlineTagContext(javadocContext0, 0);
CommonToken javadocInlineTagStart1 = new CommonToken(JavadocTokenTypes.JAVADOC_INLINE_TAG_START, "{");
javadocInlineTagContext1.addChild(javadocInlineTagStart1);
CommonToken linkLiteral1 = new CommonToken(JavadocTokenTypes.LINK_LITERAL, "@link");
javadocInlineTagContext1.addChild(linkLiteral1);
CommonToken ws1 = new CommonToken(JavadocTokenTypes.WS, " ");
javadocInlineTagContext1.addChild(ws1);
ReferenceContext referenceContext1 = new ReferenceContext(javadocInlineTagContext1, 0);
CommonToken package1 = new CommonToken(JavadocTokenTypes.PACKAGE, "java.lang");
referenceContext1.addChild(package1);
CommonToken dot1 = new CommonToken(JavadocTokenTypes.DOT, ".");
referenceContext1.addChild(dot1);
CommonToken class1 = new CommonToken(JavadocTokenTypes.CLASS, "Integer");
referenceContext1.addChild(class1);
CommonToken hash1 = new CommonToken(JavadocTokenTypes.HASH, "#");
referenceContext1.addChild(hash1);
CommonToken member1 = new CommonToken(JavadocTokenTypes.MEMBER, "valueOf");
referenceContext1.addChild(member1);
javadocInlineTagContext1.addChild(referenceContext1);
DescriptionContext descriptionContext0 = new DescriptionContext(javadocInlineTagContext1, 0);
TextContext textContext0 = new TextContext(descriptionContext0, 0);
CommonToken ws2 = new CommonToken(JavadocTokenTypes.WS, " ");
textContext0.addChild(ws2);
CommonToken char0 = new CommonToken(JavadocTokenTypes.CHAR, "v");
textContext0.addChild(char0);
CommonToken char1 = new CommonToken(JavadocTokenTypes.CHAR, "a");
textContext0.addChild(char1);
CommonToken char2 = new CommonToken(JavadocTokenTypes.CHAR, "l");
textContext0.addChild(char2);
CommonToken char3 = new CommonToken(JavadocTokenTypes.CHAR, "u");
textContext0.addChild(char3);
CommonToken char4 = new CommonToken(JavadocTokenTypes.CHAR, "e");
textContext0.addChild(char4);
CommonToken char5 = new CommonToken(JavadocTokenTypes.CHAR, "O");
textContext0.addChild(char5);
CommonToken char6 = new CommonToken(JavadocTokenTypes.CHAR, "f");
textContext0.addChild(char6);
descriptionContext0.addChild(textContext0);
javadocInlineTagContext1.addChild(descriptionContext0);
CommonToken javadocInlineTagEnd1 = new CommonToken(JavadocTokenTypes.JAVADOC_INLINE_TAG_END, "}");
javadocInlineTagContext1.addChild(javadocInlineTagEnd1);
javadocContext0.addChild(javadocInlineTagContext1);
CommonToken eof0 = new CommonToken(JavadocTokenTypes.EOF, "<EOF>");
javadocContext0.addChild(eof0);
return javadocContext0;
}
Aggregations