com.sun.tools.javac.parser.DocCommentParser.TagParser.Kind Java Examples
The following examples show how to use
com.sun.tools.javac.parser.DocCommentParser.TagParser.Kind.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: DocCommentParser.java From openjdk-jdk9 with GNU General Public License v2.0 | 5 votes |
/** * Read a single inline tag, including its content. * Standard tags parse their content appropriately. * Non-standard tags are represented by {@link UnknownBlockTag}. * Malformed tags may be returned as {@link Erroneous}. */ protected DCTree inlineTag() { int p = bp - 1; try { nextChar(); if (isIdentifierStart(ch)) { Name name = readTagName(); TagParser tp = tagParsers.get(name); if (tp == null) { skipWhitespace(); DCTree text = inlineText(WhitespaceRetentionPolicy.REMOVE_ALL); if (text != null) { nextChar(); return m.at(p).newUnknownInlineTagTree(name, List.of(text)).setEndPos(bp); } } else { if (!tp.retainWhiteSpace) { skipWhitespace(); } if (tp.getKind() == TagParser.Kind.INLINE) { DCEndPosTree<?> tree = (DCEndPosTree<?>) tp.parse(p); if (tree != null) { return tree.setEndPos(bp); } } else { // handle block tags (ex: @see) in inline content inlineText(WhitespaceRetentionPolicy.REMOVE_ALL); // skip content nextChar(); } } } return erroneous("dc.no.tag.name", p); } catch (ParseException e) { return erroneous(e.getMessage(), p); } }
Example #2
Source File: DocCommentParser.java From TencentKona-8 with GNU General Public License v2.0 | 5 votes |
/** * Read a single inline tag, including its content. * Standard tags parse their content appropriately. * Non-standard tags are represented by {@link UnknownBlockTag}. * Malformed tags may be returned as {@link Erroneous}. */ protected DCTree inlineTag() { int p = bp - 1; try { nextChar(); if (isIdentifierStart(ch)) { Name name = readTagName(); skipWhitespace(); TagParser tp = tagParsers.get(name); if (tp == null) { DCTree text = inlineText(); if (text != null) { nextChar(); return m.at(p).UnknownInlineTag(name, List.of(text)).setEndPos(bp); } } else if (tp.getKind() == TagParser.Kind.INLINE) { DCEndPosTree<?> tree = (DCEndPosTree<?>) tp.parse(p); if (tree != null) { return tree.setEndPos(bp); } } else { inlineText(); // skip content nextChar(); } } return erroneous("dc.no.tag.name", p); } catch (ParseException e) { return erroneous(e.getMessage(), p); } }
Example #3
Source File: DocCommentParser.java From jdk8u60 with GNU General Public License v2.0 | 5 votes |
/** * Read a single inline tag, including its content. * Standard tags parse their content appropriately. * Non-standard tags are represented by {@link UnknownBlockTag}. * Malformed tags may be returned as {@link Erroneous}. */ protected DCTree inlineTag() { int p = bp - 1; try { nextChar(); if (isIdentifierStart(ch)) { Name name = readTagName(); skipWhitespace(); TagParser tp = tagParsers.get(name); if (tp == null) { DCTree text = inlineText(); if (text != null) { nextChar(); return m.at(p).UnknownInlineTag(name, List.of(text)).setEndPos(bp); } } else if (tp.getKind() == TagParser.Kind.INLINE) { DCEndPosTree<?> tree = (DCEndPosTree<?>) tp.parse(p); if (tree != null) { return tree.setEndPos(bp); } } else { inlineText(); // skip content nextChar(); } } return erroneous("dc.no.tag.name", p); } catch (ParseException e) { return erroneous(e.getMessage(), p); } }
Example #4
Source File: DocCommentParser.java From openjdk-8 with GNU General Public License v2.0 | 5 votes |
/** * Read a single inline tag, including its content. * Standard tags parse their content appropriately. * Non-standard tags are represented by {@link UnknownBlockTag}. * Malformed tags may be returned as {@link Erroneous}. */ protected DCTree inlineTag() { int p = bp - 1; try { nextChar(); if (isIdentifierStart(ch)) { Name name = readTagName(); skipWhitespace(); TagParser tp = tagParsers.get(name); if (tp == null) { DCTree text = inlineText(); if (text != null) { nextChar(); return m.at(p).UnknownInlineTag(name, List.of(text)).setEndPos(bp); } } else if (tp.getKind() == TagParser.Kind.INLINE) { DCEndPosTree<?> tree = (DCEndPosTree<?>) tp.parse(p); if (tree != null) { return tree.setEndPos(bp); } } else { inlineText(); // skip content nextChar(); } } return erroneous("dc.no.tag.name", p); } catch (ParseException e) { return erroneous(e.getMessage(), p); } }
Example #5
Source File: DocCommentParser.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 5 votes |
/** * Read a single inline tag, including its content. * Standard tags parse their content appropriately. * Non-standard tags are represented by {@link UnknownBlockTag}. * Malformed tags may be returned as {@link Erroneous}. */ protected DCTree inlineTag() { int p = bp - 1; try { nextChar(); if (isIdentifierStart(ch)) { Name name = readTagName(); skipWhitespace(); TagParser tp = tagParsers.get(name); if (tp == null) { DCTree text = inlineText(); if (text != null) { nextChar(); return m.at(p).UnknownInlineTag(name, List.of(text)).setEndPos(bp); } } else if (tp.getKind() == TagParser.Kind.INLINE) { DCEndPosTree<?> tree = (DCEndPosTree<?>) tp.parse(p); if (tree != null) { return tree.setEndPos(bp); } } else { inlineText(); // skip content nextChar(); } } return erroneous("dc.no.tag.name", p); } catch (ParseException e) { return erroneous(e.getMessage(), p); } }
Example #6
Source File: DocCommentParser.java From openjdk-jdk8u with GNU General Public License v2.0 | 5 votes |
/** * Read a single inline tag, including its content. * Standard tags parse their content appropriately. * Non-standard tags are represented by {@link UnknownBlockTag}. * Malformed tags may be returned as {@link Erroneous}. */ protected DCTree inlineTag() { int p = bp - 1; try { nextChar(); if (isIdentifierStart(ch)) { Name name = readTagName(); skipWhitespace(); TagParser tp = tagParsers.get(name); if (tp == null) { DCTree text = inlineText(); if (text != null) { nextChar(); return m.at(p).UnknownInlineTag(name, List.of(text)).setEndPos(bp); } } else if (tp.getKind() == TagParser.Kind.INLINE) { DCEndPosTree<?> tree = (DCEndPosTree<?>) tp.parse(p); if (tree != null) { return tree.setEndPos(bp); } } else { inlineText(); // skip content nextChar(); } } return erroneous("dc.no.tag.name", p); } catch (ParseException e) { return erroneous(e.getMessage(), p); } }
Example #7
Source File: DocCommentParser.java From openjdk-8-source with GNU General Public License v2.0 | 5 votes |
/** * Read a single inline tag, including its content. * Standard tags parse their content appropriately. * Non-standard tags are represented by {@link UnknownBlockTag}. * Malformed tags may be returned as {@link Erroneous}. */ protected DCTree inlineTag() { int p = bp - 1; try { nextChar(); if (isIdentifierStart(ch)) { Name name = readTagName(); skipWhitespace(); TagParser tp = tagParsers.get(name); if (tp == null) { DCTree text = inlineText(); if (text != null) { nextChar(); return m.at(p).UnknownInlineTag(name, List.of(text)).setEndPos(bp); } } else if (tp.getKind() == TagParser.Kind.INLINE) { DCEndPosTree<?> tree = (DCEndPosTree<?>) tp.parse(p); if (tree != null) { return tree.setEndPos(bp); } } else { inlineText(); // skip content nextChar(); } } return erroneous("dc.no.tag.name", p); } catch (ParseException e) { return erroneous(e.getMessage(), p); } }
Example #8
Source File: DocCommentParser.java From hottub with GNU General Public License v2.0 | 5 votes |
/** * Read a single inline tag, including its content. * Standard tags parse their content appropriately. * Non-standard tags are represented by {@link UnknownBlockTag}. * Malformed tags may be returned as {@link Erroneous}. */ protected DCTree inlineTag() { int p = bp - 1; try { nextChar(); if (isIdentifierStart(ch)) { Name name = readTagName(); skipWhitespace(); TagParser tp = tagParsers.get(name); if (tp == null) { DCTree text = inlineText(); if (text != null) { nextChar(); return m.at(p).UnknownInlineTag(name, List.of(text)).setEndPos(bp); } } else if (tp.getKind() == TagParser.Kind.INLINE) { DCEndPosTree<?> tree = (DCEndPosTree<?>) tp.parse(p); if (tree != null) { return tree.setEndPos(bp); } } else { inlineText(); // skip content nextChar(); } } return erroneous("dc.no.tag.name", p); } catch (ParseException e) { return erroneous(e.getMessage(), p); } }
Example #9
Source File: DocCommentParser.java From lua-for-android with BSD 3-Clause "New" or "Revised" License | 5 votes |
/** * Read a single inline tag, including its content. * Standard tags parse their content appropriately. * Non-standard tags are represented by {@link UnknownBlockTag}. * Malformed tags may be returned as {@link Erroneous}. */ protected DCTree inlineTag() { int p = bp - 1; try { nextChar(); if (isIdentifierStart(ch)) { Name name = readTagName(); TagParser tp = tagParsers.get(name); if (tp == null) { skipWhitespace(); DCTree text = inlineText(WhitespaceRetentionPolicy.REMOVE_ALL); if (text != null) { nextChar(); return m.at(p).newUnknownInlineTagTree(name, List.of(text)).setEndPos(bp); } } else { if (!tp.retainWhiteSpace) { skipWhitespace(); } if (tp.getKind() == TagParser.Kind.INLINE) { DCEndPosTree<?> tree = (DCEndPosTree<?>) tp.parse(p); if (tree != null) { return tree.setEndPos(bp); } } else { // handle block tags (ex: @see) in inline content inlineText(WhitespaceRetentionPolicy.REMOVE_ALL); // skip content nextChar(); } } } return erroneous("dc.no.tag.name", p); } catch (ParseException e) { return erroneous(e.getMessage(), p); } }
Example #10
Source File: DocCommentParser.java From hottub with GNU General Public License v2.0 | 4 votes |
DCTree.Kind getTreeKind() { return treeKind; }
Example #11
Source File: DocCommentParser.java From openjdk-jdk9 with GNU General Public License v2.0 | 4 votes |
TagParser(Kind k, DCTree.Kind tk, boolean retainWhiteSpace) { kind = k; treeKind = tk; this.retainWhiteSpace = retainWhiteSpace; }
Example #12
Source File: DocCommentParser.java From openjdk-jdk9 with GNU General Public License v2.0 | 4 votes |
Kind getKind() { return kind; }
Example #13
Source File: DocCommentParser.java From openjdk-jdk9 with GNU General Public License v2.0 | 4 votes |
DCTree.Kind getTreeKind() { return treeKind; }
Example #14
Source File: DocCommentParser.java From hottub with GNU General Public License v2.0 | 4 votes |
TagParser(Kind k, DCTree.Kind tk) { kind = k; treeKind = tk; }
Example #15
Source File: DocCommentParser.java From hottub with GNU General Public License v2.0 | 4 votes |
Kind getKind() { return kind; }
Example #16
Source File: DocCommentParser.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 4 votes |
Kind getKind() { return kind; }
Example #17
Source File: DocCommentParser.java From openjdk-8-source with GNU General Public License v2.0 | 4 votes |
TagParser(Kind k, DCTree.Kind tk) { kind = k; treeKind = tk; }
Example #18
Source File: DocCommentParser.java From openjdk-8-source with GNU General Public License v2.0 | 4 votes |
Kind getKind() { return kind; }
Example #19
Source File: DocCommentParser.java From openjdk-8-source with GNU General Public License v2.0 | 4 votes |
DCTree.Kind getTreeKind() { return treeKind; }
Example #20
Source File: DocCommentParser.java From openjdk-8 with GNU General Public License v2.0 | 4 votes |
TagParser(Kind k, DCTree.Kind tk) { kind = k; treeKind = tk; }
Example #21
Source File: DocCommentParser.java From openjdk-8 with GNU General Public License v2.0 | 4 votes |
Kind getKind() { return kind; }
Example #22
Source File: DocCommentParser.java From openjdk-8 with GNU General Public License v2.0 | 4 votes |
DCTree.Kind getTreeKind() { return treeKind; }
Example #23
Source File: DocCommentParser.java From openjdk-jdk9 with GNU General Public License v2.0 | 4 votes |
TagParser(Kind k, DCTree.Kind tk) { kind = k; treeKind = tk; retainWhiteSpace = false; }
Example #24
Source File: DocCommentParser.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 4 votes |
DCTree.Kind getTreeKind() { return treeKind; }
Example #25
Source File: DocCommentParser.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 4 votes |
TagParser(Kind k, DCTree.Kind tk) { kind = k; treeKind = tk; }
Example #26
Source File: DocCommentParser.java From lua-for-android with BSD 3-Clause "New" or "Revised" License | 4 votes |
DCTree.Kind getTreeKind() { return treeKind; }
Example #27
Source File: DocCommentParser.java From lua-for-android with BSD 3-Clause "New" or "Revised" License | 4 votes |
Kind getKind() { return kind; }
Example #28
Source File: DocCommentParser.java From lua-for-android with BSD 3-Clause "New" or "Revised" License | 4 votes |
TagParser(Kind k, DCTree.Kind tk, boolean retainWhiteSpace) { kind = k; treeKind = tk; this.retainWhiteSpace = retainWhiteSpace; }
Example #29
Source File: DocCommentParser.java From lua-for-android with BSD 3-Clause "New" or "Revised" License | 4 votes |
TagParser(Kind k, DCTree.Kind tk) { kind = k; treeKind = tk; retainWhiteSpace = false; }
Example #30
Source File: DocCommentParser.java From openjdk-jdk8u with GNU General Public License v2.0 | 4 votes |
DCTree.Kind getTreeKind() { return treeKind; }