Search in sources :

Example 11 with JavadocTagContext

use of com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.JavadocTagContext in project checkstyle by checkstyle.

the class ParseTreeBuilder method treeSeeReferenceWithFewNestedClasses.

public static ParseTree treeSeeReferenceWithFewNestedClasses() {
    JavadocContext javadocContext0 = new JavadocContext(null, 0);
    JavadocTagContext javadocTagContext0 = new JavadocTagContext(javadocContext0, 0);
    CommonToken seeLiteral0 = new CommonToken(JavadocTokenTypes.SEE_LITERAL, "@see");
    javadocTagContext0.addChild(seeLiteral0);
    CommonToken ws0 = new CommonToken(JavadocTokenTypes.WS, " ");
    javadocTagContext0.addChild(ws0);
    ReferenceContext referenceContext0 = new ReferenceContext(javadocTagContext0, 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 dot1 = new CommonToken(JavadocTokenTypes.DOT, ".");
    referenceContext0.addChild(dot1);
    CommonToken class1 = new CommonToken(JavadocTokenTypes.CLASS, "Nested");
    referenceContext0.addChild(class1);
    CommonToken dot2 = new CommonToken(JavadocTokenTypes.DOT, ".");
    referenceContext0.addChild(dot2);
    CommonToken class2 = new CommonToken(JavadocTokenTypes.CLASS, "AnotherNested");
    referenceContext0.addChild(class2);
    CommonToken hash0 = new CommonToken(JavadocTokenTypes.HASH, "#");
    referenceContext0.addChild(hash0);
    CommonToken member0 = new CommonToken(JavadocTokenTypes.MEMBER, "someMethod");
    referenceContext0.addChild(member0);
    ParametersContext parametersContext0 = new ParametersContext(referenceContext0, 0);
    CommonToken leftBrace0 = new CommonToken(JavadocTokenTypes.LEFT_BRACE, "(");
    parametersContext0.addChild(leftBrace0);
    CommonToken argument0 = new CommonToken(JavadocTokenTypes.ARGUMENT, "String");
    parametersContext0.addChild(argument0);
    CommonToken comma0 = new CommonToken(JavadocTokenTypes.COMMA, ",");
    parametersContext0.addChild(comma0);
    CommonToken ws1 = new CommonToken(JavadocTokenTypes.WS, " ");
    parametersContext0.addChild(ws1);
    CommonToken argument1 = new CommonToken(JavadocTokenTypes.ARGUMENT, "int");
    parametersContext0.addChild(argument1);
    CommonToken rightBrace0 = new CommonToken(JavadocTokenTypes.RIGHT_BRACE, ")");
    parametersContext0.addChild(rightBrace0);
    referenceContext0.addChild(parametersContext0);
    javadocTagContext0.addChild(referenceContext0);
    CommonToken ws2 = new CommonToken(JavadocTokenTypes.WS, " ");
    javadocTagContext0.addChild(ws2);
    DescriptionContext descriptionContext0 = new DescriptionContext(javadocTagContext0, 0);
    TextContext textContext0 = new TextContext(descriptionContext0, 0);
    CommonToken char0 = new CommonToken(JavadocTokenTypes.CHAR, "D");
    textContext0.addChild(char0);
    CommonToken char1 = new CommonToken(JavadocTokenTypes.CHAR, "e");
    textContext0.addChild(char1);
    CommonToken char2 = new CommonToken(JavadocTokenTypes.CHAR, "s");
    textContext0.addChild(char2);
    CommonToken char3 = new CommonToken(JavadocTokenTypes.CHAR, "c");
    textContext0.addChild(char3);
    CommonToken char4 = new CommonToken(JavadocTokenTypes.CHAR, "r");
    textContext0.addChild(char4);
    CommonToken char5 = new CommonToken(JavadocTokenTypes.CHAR, "i");
    textContext0.addChild(char5);
    CommonToken char6 = new CommonToken(JavadocTokenTypes.CHAR, "p");
    textContext0.addChild(char6);
    CommonToken char7 = new CommonToken(JavadocTokenTypes.CHAR, "t");
    textContext0.addChild(char7);
    CommonToken char8 = new CommonToken(JavadocTokenTypes.CHAR, "i");
    textContext0.addChild(char8);
    CommonToken char9 = new CommonToken(JavadocTokenTypes.CHAR, "o");
    textContext0.addChild(char9);
    CommonToken char10 = new CommonToken(JavadocTokenTypes.CHAR, "n");
    textContext0.addChild(char10);
    CommonToken ws3 = new CommonToken(JavadocTokenTypes.WS, " ");
    textContext0.addChild(ws3);
    CommonToken char11 = new CommonToken(JavadocTokenTypes.CHAR, "o");
    textContext0.addChild(char11);
    CommonToken char12 = new CommonToken(JavadocTokenTypes.CHAR, "f");
    textContext0.addChild(char12);
    CommonToken ws4 = new CommonToken(JavadocTokenTypes.WS, " ");
    textContext0.addChild(ws4);
    CommonToken char13 = new CommonToken(JavadocTokenTypes.CHAR, "t");
    textContext0.addChild(char13);
    CommonToken char14 = new CommonToken(JavadocTokenTypes.CHAR, "h");
    textContext0.addChild(char14);
    CommonToken char15 = new CommonToken(JavadocTokenTypes.CHAR, "e");
    textContext0.addChild(char15);
    CommonToken ws5 = new CommonToken(JavadocTokenTypes.WS, " ");
    textContext0.addChild(ws5);
    CommonToken char16 = new CommonToken(JavadocTokenTypes.CHAR, "l");
    textContext0.addChild(char16);
    CommonToken char17 = new CommonToken(JavadocTokenTypes.CHAR, "i");
    textContext0.addChild(char17);
    CommonToken char18 = new CommonToken(JavadocTokenTypes.CHAR, "n");
    textContext0.addChild(char18);
    CommonToken char19 = new CommonToken(JavadocTokenTypes.CHAR, "k");
    textContext0.addChild(char19);
    descriptionContext0.addChild(textContext0);
    javadocTagContext0.addChild(descriptionContext0);
    javadocContext0.addChild(javadocTagContext0);
    CommonToken eof0 = new CommonToken(JavadocTokenTypes.EOF, "<EOF>");
    javadocContext0.addChild(eof0);
    return javadocContext0;
}
Also used : ParametersContext(com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.ParametersContext) TextContext(com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.TextContext) JavadocContext(com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.JavadocContext) ReferenceContext(com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.ReferenceContext) JavadocTagContext(com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.JavadocTagContext) CommonToken(org.antlr.v4.runtime.CommonToken) DescriptionContext(com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.DescriptionContext)

Example 12 with JavadocTagContext

use of com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.JavadocTagContext in project checkstyle by checkstyle.

the class ParseTreeBuilder method treeFewWhiteSpacesAsSeparator.

public static ParseTree treeFewWhiteSpacesAsSeparator() {
    JavadocContext javadocContext0 = new JavadocContext(null, 0);
    CommonToken leadingAsterisk0 = new CommonToken(JavadocTokenTypes.LEADING_ASTERISK, "       *");
    javadocContext0.addChild(leadingAsterisk0);
    CommonToken ws0 = new CommonToken(JavadocTokenTypes.WS, " ");
    javadocContext0.addChild(ws0);
    JavadocTagContext javadocTagContext0 = new JavadocTagContext(javadocContext0, 0);
    CommonToken paramLiteral0 = new CommonToken(JavadocTokenTypes.PARAM_LITERAL, "@param");
    javadocTagContext0.addChild(paramLiteral0);
    CommonToken ws1 = new CommonToken(JavadocTokenTypes.WS, "   ");
    javadocTagContext0.addChild(ws1);
    CommonToken parameterName0 = new CommonToken(JavadocTokenTypes.PARAMETER_NAME, "initialCapacity");
    javadocTagContext0.addChild(parameterName0);
    CommonToken ws2 = new CommonToken(JavadocTokenTypes.WS, "     ");
    javadocTagContext0.addChild(ws2);
    DescriptionContext descriptionContext0 = new DescriptionContext(javadocTagContext0, 0);
    TextContext textContext0 = new TextContext(descriptionContext0, 0);
    CommonToken char0 = new CommonToken(JavadocTokenTypes.CHAR, "t");
    textContext0.addChild(char0);
    CommonToken char1 = new CommonToken(JavadocTokenTypes.CHAR, "h");
    textContext0.addChild(char1);
    CommonToken char2 = new CommonToken(JavadocTokenTypes.CHAR, "e");
    textContext0.addChild(char2);
    CommonToken ws3 = new CommonToken(JavadocTokenTypes.WS, " ");
    textContext0.addChild(ws3);
    CommonToken char3 = new CommonToken(JavadocTokenTypes.CHAR, "i");
    textContext0.addChild(char3);
    CommonToken char4 = new CommonToken(JavadocTokenTypes.CHAR, "n");
    textContext0.addChild(char4);
    CommonToken char5 = new CommonToken(JavadocTokenTypes.CHAR, "i");
    textContext0.addChild(char5);
    CommonToken char6 = new CommonToken(JavadocTokenTypes.CHAR, "t");
    textContext0.addChild(char6);
    CommonToken char7 = new CommonToken(JavadocTokenTypes.CHAR, "i");
    textContext0.addChild(char7);
    CommonToken char8 = new CommonToken(JavadocTokenTypes.CHAR, "a");
    textContext0.addChild(char8);
    CommonToken char9 = new CommonToken(JavadocTokenTypes.CHAR, "l");
    textContext0.addChild(char9);
    CommonToken ws4 = new CommonToken(JavadocTokenTypes.WS, " ");
    textContext0.addChild(ws4);
    CommonToken char10 = new CommonToken(JavadocTokenTypes.CHAR, "c");
    textContext0.addChild(char10);
    CommonToken char11 = new CommonToken(JavadocTokenTypes.CHAR, "a");
    textContext0.addChild(char11);
    CommonToken char12 = new CommonToken(JavadocTokenTypes.CHAR, "p");
    textContext0.addChild(char12);
    CommonToken char13 = new CommonToken(JavadocTokenTypes.CHAR, "a");
    textContext0.addChild(char13);
    CommonToken char14 = new CommonToken(JavadocTokenTypes.CHAR, "c");
    textContext0.addChild(char14);
    CommonToken char15 = new CommonToken(JavadocTokenTypes.CHAR, "i");
    textContext0.addChild(char15);
    CommonToken char16 = new CommonToken(JavadocTokenTypes.CHAR, "t");
    textContext0.addChild(char16);
    CommonToken char17 = new CommonToken(JavadocTokenTypes.CHAR, "y");
    textContext0.addChild(char17);
    CommonToken ws5 = new CommonToken(JavadocTokenTypes.WS, " ");
    textContext0.addChild(ws5);
    CommonToken char18 = new CommonToken(JavadocTokenTypes.CHAR, "o");
    textContext0.addChild(char18);
    CommonToken char19 = new CommonToken(JavadocTokenTypes.CHAR, "f");
    textContext0.addChild(char19);
    CommonToken ws6 = new CommonToken(JavadocTokenTypes.WS, " ");
    textContext0.addChild(ws6);
    CommonToken char20 = new CommonToken(JavadocTokenTypes.CHAR, "t");
    textContext0.addChild(char20);
    CommonToken char21 = new CommonToken(JavadocTokenTypes.CHAR, "h");
    textContext0.addChild(char21);
    CommonToken char22 = new CommonToken(JavadocTokenTypes.CHAR, "e");
    textContext0.addChild(char22);
    CommonToken ws7 = new CommonToken(JavadocTokenTypes.WS, " ");
    textContext0.addChild(ws7);
    CommonToken char23 = new CommonToken(JavadocTokenTypes.CHAR, "B");
    textContext0.addChild(char23);
    CommonToken char24 = new CommonToken(JavadocTokenTypes.CHAR, "y");
    textContext0.addChild(char24);
    CommonToken char25 = new CommonToken(JavadocTokenTypes.CHAR, "t");
    textContext0.addChild(char25);
    CommonToken char26 = new CommonToken(JavadocTokenTypes.CHAR, "e");
    textContext0.addChild(char26);
    CommonToken char27 = new CommonToken(JavadocTokenTypes.CHAR, "B");
    textContext0.addChild(char27);
    CommonToken char28 = new CommonToken(JavadocTokenTypes.CHAR, "u");
    textContext0.addChild(char28);
    CommonToken char29 = new CommonToken(JavadocTokenTypes.CHAR, "f");
    textContext0.addChild(char29);
    CommonToken char30 = new CommonToken(JavadocTokenTypes.CHAR, "f");
    textContext0.addChild(char30);
    CommonToken char31 = new CommonToken(JavadocTokenTypes.CHAR, "e");
    textContext0.addChild(char31);
    CommonToken char32 = new CommonToken(JavadocTokenTypes.CHAR, "r");
    textContext0.addChild(char32);
    CommonToken char33 = new CommonToken(JavadocTokenTypes.CHAR, ".");
    textContext0.addChild(char33);
    descriptionContext0.addChild(textContext0);
    javadocTagContext0.addChild(descriptionContext0);
    javadocContext0.addChild(javadocTagContext0);
    CommonToken eof0 = new CommonToken(JavadocTokenTypes.EOF, "<EOF>");
    javadocContext0.addChild(eof0);
    return javadocContext0;
}
Also used : TextContext(com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.TextContext) JavadocContext(com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.JavadocContext) JavadocTagContext(com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.JavadocTagContext) CommonToken(org.antlr.v4.runtime.CommonToken) DescriptionContext(com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.DescriptionContext)

Aggregations

DescriptionContext (com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.DescriptionContext)12 JavadocContext (com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.JavadocContext)12 JavadocTagContext (com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.JavadocTagContext)12 TextContext (com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.TextContext)12 CommonToken (org.antlr.v4.runtime.CommonToken)12 ReferenceContext (com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.ReferenceContext)4 AttributeContext (com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.AttributeContext)3 HtmlElementContext (com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.HtmlElementContext)3 HtmlElementCloseContext (com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.HtmlElementCloseContext)2 HtmlElementOpenContext (com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.HtmlElementOpenContext)2 HtmlTagContext (com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.HtmlTagContext)2 ParametersContext (com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.ParametersContext)2 JavadocInlineTagContext (com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.JavadocInlineTagContext)1 PTagOpenContext (com.puppycrawl.tools.checkstyle.grammars.javadoc.JavadocParser.PTagOpenContext)1