< prev index next >

src/jdk.compiler/share/classes/com/sun/tools/javac/parser/DocCommentParser.java

Print this page

        

*** 28,37 **** --- 28,38 ---- import java.text.BreakIterator; import java.util.HashMap; import java.util.Map; import com.sun.source.doctree.AttributeTree.ValueKind; + import com.sun.source.doctree.DocTree; import com.sun.tools.javac.parser.DocCommentParser.TagParser.Kind; import com.sun.tools.javac.parser.Tokens.Comment; import com.sun.tools.javac.parser.Tokens.TokenKind; import com.sun.tools.javac.tree.DCTree; import com.sun.tools.javac.tree.DCTree.DCAttribute;
*** 1320,1329 **** --- 1321,1336 ---- nextChar(); return m.at(pos).newLiteralTree((DCText) text); } }, + // {@getter text} + new AccessorParser(DCTree.Kind.GETTER), + + // {@getter text} + new AccessorParser(DCTree.Kind.SETTER), + // @param parameter-name description new TagParser(Kind.BLOCK, DCTree.Kind.PARAM) { public DCTree parse(int pos) throws ParseException { skipWhitespace();
*** 1525,1530 **** --- 1532,1547 ---- for (TagParser p: parsers) tagParsers.put(names.fromString(p.getTreeKind().tagName), p); } + class AccessorParser extends TagParser { + AccessorParser(DocTree.Kind kind) { + super(Kind.BLOCK, kind, true); + } + + public DCTree parse(int pos) throws ParseException { + List<DCTree> desc = blockContent(); + return m.at(pos).newAccessorTree(treeKind, desc); + } + } }
< prev index next >