Java Code Examples for com.sun.xml.internal.rngom.ast.builder.Annotations#addComment()

The following examples show how to use com.sun.xml.internal.rngom.ast.builder.Annotations#addComment() . 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: CompactSyntax.java    From TencentKona-8 with GNU General Public License v2.0 5 votes vote down vote up
private Annotations addCommentsToChildAnnotations(Annotations a) {
  CommentList comments = getComments();
  if (comments == null)
    return a;
  if (a == null)
    a = sb.makeAnnotations(null, getContext());
  a.addComment(comments);
  return a;
}
 
Example 2
Source File: CompactSyntax.java    From jdk8u60 with GNU General Public License v2.0 5 votes vote down vote up
private Annotations addCommentsToChildAnnotations(Annotations a) {
  CommentList comments = getComments();
  if (comments == null)
    return a;
  if (a == null)
    a = sb.makeAnnotations(null, getContext());
  a.addComment(comments);
  return a;
}
 
Example 3
Source File: CompactSyntax.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
private Annotations addCommentsToChildAnnotations(Annotations a) {
  CommentList comments = getComments();
  if (comments == null)
    return a;
  if (a == null)
    a = sb.makeAnnotations(null, getContext());
  a.addComment(comments);
  return a;
}
 
Example 4
Source File: CompactSyntax.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 5 votes vote down vote up
private Annotations addCommentsToChildAnnotations(Annotations a) {
  CommentList comments = getComments();
  if (comments == null)
    return a;
  if (a == null)
    a = sb.makeAnnotations(null, getContext());
  a.addComment(comments);
  return a;
}
 
Example 5
Source File: CompactSyntax.java    From openjdk-jdk9 with GNU General Public License v2.0 5 votes vote down vote up
private Annotations addCommentsToChildAnnotations(Annotations a) {
  CommentList comments = getComments();
  if (comments == null)
    return a;
  if (a == null)
    a = sb.makeAnnotations(null, getContext());
  a.addComment(comments);
  return a;
}
 
Example 6
Source File: CompactSyntax.java    From hottub with GNU General Public License v2.0 5 votes vote down vote up
private Annotations addCommentsToChildAnnotations(Annotations a) {
  CommentList comments = getComments();
  if (comments == null)
    return a;
  if (a == null)
    a = sb.makeAnnotations(null, getContext());
  a.addComment(comments);
  return a;
}
 
Example 7
Source File: CompactSyntax.java    From openjdk-8-source with GNU General Public License v2.0 5 votes vote down vote up
private Annotations addCommentsToChildAnnotations(Annotations a) {
  CommentList comments = getComments();
  if (comments == null)
    return a;
  if (a == null)
    a = sb.makeAnnotations(null, getContext());
  a.addComment(comments);
  return a;
}
 
Example 8
Source File: CompactSyntax.java    From openjdk-8 with GNU General Public License v2.0 5 votes vote down vote up
private Annotations addCommentsToChildAnnotations(Annotations a) {
  CommentList comments = getComments();
  if (comments == null)
    return a;
  if (a == null)
    a = sb.makeAnnotations(null, getContext());
  a.addComment(comments);
  return a;
}
 
Example 9
Source File: CompactSyntax.java    From TencentKona-8 with GNU General Public License v2.0 4 votes vote down vote up
final public Annotations Annotations() throws ParseException {
CommentList comments = getComments();
Annotations a = null;
ParsedElementAnnotation e;
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case DOCUMENTATION:
  case DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT:
    a = sb.makeAnnotations(comments, getContext());
    label_20:
    while (true) {
      e = Documentation();
                         a.addElement(e);
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case DOCUMENTATION:
      case DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT:
        ;
        break;
      default:
        jj_la1[56] = jj_gen;
        break label_20;
      }
    }
    comments = getComments();
    if (comments != null)
      a.addLeadingComment(comments);
    break;
  default:
    jj_la1[57] = jj_gen;
    ;
  }
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case 1:
    jj_consume_token(1);
       if (a == null) a = sb.makeAnnotations(comments, getContext()); clearAttributeList(); annotationsIncludeElements = false;
    label_21:
    while (true) {
      if (jj_2_7(2)) {
        ;
      } else {
        break label_21;
      }
      PrefixedAnnotationAttribute(a, false);
    }
    label_22:
    while (true) {
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case 5:
      case 6:
      case 7:
      case 10:
      case 13:
      case 14:
      case 15:
      case 16:
      case 17:
      case 18:
      case 19:
      case 26:
      case 27:
      case 31:
      case 32:
      case 33:
      case 34:
      case 35:
      case 36:
      case IDENTIFIER:
      case ESCAPED_IDENTIFIER:
      case PREFIXED_NAME:
        ;
        break;
      default:
        jj_la1[58] = jj_gen;
        break label_22;
      }
      e = AnnotationElement(false);
                                      a.addElement(e); annotationsIncludeElements = true;
    }
       a.addComment(getComments());
    jj_consume_token(9);
    break;
  default:
    jj_la1[59] = jj_gen;
    ;
  }
  if (a == null && comments != null)
    a = sb.makeAnnotations(comments, getContext());
  {if (true) return a;}
  throw new Error("Missing return statement in function");
}
 
Example 10
Source File: CompactSyntax.java    From jdk8u60 with GNU General Public License v2.0 4 votes vote down vote up
final public Annotations Annotations() throws ParseException {
CommentList comments = getComments();
Annotations a = null;
ParsedElementAnnotation e;
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case DOCUMENTATION:
  case DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT:
    a = sb.makeAnnotations(comments, getContext());
    label_20:
    while (true) {
      e = Documentation();
                         a.addElement(e);
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case DOCUMENTATION:
      case DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT:
        ;
        break;
      default:
        jj_la1[56] = jj_gen;
        break label_20;
      }
    }
    comments = getComments();
    if (comments != null)
      a.addLeadingComment(comments);
    break;
  default:
    jj_la1[57] = jj_gen;
    ;
  }
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case 1:
    jj_consume_token(1);
       if (a == null) a = sb.makeAnnotations(comments, getContext()); clearAttributeList(); annotationsIncludeElements = false;
    label_21:
    while (true) {
      if (jj_2_7(2)) {
        ;
      } else {
        break label_21;
      }
      PrefixedAnnotationAttribute(a, false);
    }
    label_22:
    while (true) {
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case 5:
      case 6:
      case 7:
      case 10:
      case 13:
      case 14:
      case 15:
      case 16:
      case 17:
      case 18:
      case 19:
      case 26:
      case 27:
      case 31:
      case 32:
      case 33:
      case 34:
      case 35:
      case 36:
      case IDENTIFIER:
      case ESCAPED_IDENTIFIER:
      case PREFIXED_NAME:
        ;
        break;
      default:
        jj_la1[58] = jj_gen;
        break label_22;
      }
      e = AnnotationElement(false);
                                      a.addElement(e); annotationsIncludeElements = true;
    }
       a.addComment(getComments());
    jj_consume_token(9);
    break;
  default:
    jj_la1[59] = jj_gen;
    ;
  }
  if (a == null && comments != null)
    a = sb.makeAnnotations(comments, getContext());
  {if (true) return a;}
  throw new Error("Missing return statement in function");
}
 
Example 11
Source File: CompactSyntax.java    From openjdk-jdk8u with GNU General Public License v2.0 4 votes vote down vote up
final public Annotations Annotations() throws ParseException {
CommentList comments = getComments();
Annotations a = null;
ParsedElementAnnotation e;
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case DOCUMENTATION:
  case DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT:
    a = sb.makeAnnotations(comments, getContext());
    label_20:
    while (true) {
      e = Documentation();
                         a.addElement(e);
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case DOCUMENTATION:
      case DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT:
        ;
        break;
      default:
        jj_la1[56] = jj_gen;
        break label_20;
      }
    }
    comments = getComments();
    if (comments != null)
      a.addLeadingComment(comments);
    break;
  default:
    jj_la1[57] = jj_gen;
    ;
  }
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case 1:
    jj_consume_token(1);
       if (a == null) a = sb.makeAnnotations(comments, getContext()); clearAttributeList(); annotationsIncludeElements = false;
    label_21:
    while (true) {
      if (jj_2_7(2)) {
        ;
      } else {
        break label_21;
      }
      PrefixedAnnotationAttribute(a, false);
    }
    label_22:
    while (true) {
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case 5:
      case 6:
      case 7:
      case 10:
      case 13:
      case 14:
      case 15:
      case 16:
      case 17:
      case 18:
      case 19:
      case 26:
      case 27:
      case 31:
      case 32:
      case 33:
      case 34:
      case 35:
      case 36:
      case IDENTIFIER:
      case ESCAPED_IDENTIFIER:
      case PREFIXED_NAME:
        ;
        break;
      default:
        jj_la1[58] = jj_gen;
        break label_22;
      }
      e = AnnotationElement(false);
                                      a.addElement(e); annotationsIncludeElements = true;
    }
       a.addComment(getComments());
    jj_consume_token(9);
    break;
  default:
    jj_la1[59] = jj_gen;
    ;
  }
  if (a == null && comments != null)
    a = sb.makeAnnotations(comments, getContext());
  {if (true) return a;}
  throw new Error("Missing return statement in function");
}
 
Example 12
Source File: CompactSyntax.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 4 votes vote down vote up
final public Annotations Annotations() throws ParseException {
CommentList comments = getComments();
Annotations a = null;
ParsedElementAnnotation e;
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case DOCUMENTATION:
  case DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT:
    a = sb.makeAnnotations(comments, getContext());
    label_20:
    while (true) {
      e = Documentation();
                         a.addElement(e);
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case DOCUMENTATION:
      case DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT:
        ;
        break;
      default:
        jj_la1[56] = jj_gen;
        break label_20;
      }
    }
    comments = getComments();
    if (comments != null)
      a.addLeadingComment(comments);
    break;
  default:
    jj_la1[57] = jj_gen;
    ;
  }
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case 1:
    jj_consume_token(1);
       if (a == null) a = sb.makeAnnotations(comments, getContext()); clearAttributeList(); annotationsIncludeElements = false;
    label_21:
    while (true) {
      if (jj_2_7(2)) {
        ;
      } else {
        break label_21;
      }
      PrefixedAnnotationAttribute(a, false);
    }
    label_22:
    while (true) {
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case 5:
      case 6:
      case 7:
      case 10:
      case 13:
      case 14:
      case 15:
      case 16:
      case 17:
      case 18:
      case 19:
      case 26:
      case 27:
      case 31:
      case 32:
      case 33:
      case 34:
      case 35:
      case 36:
      case IDENTIFIER:
      case ESCAPED_IDENTIFIER:
      case PREFIXED_NAME:
        ;
        break;
      default:
        jj_la1[58] = jj_gen;
        break label_22;
      }
      e = AnnotationElement(false);
                                      a.addElement(e); annotationsIncludeElements = true;
    }
       a.addComment(getComments());
    jj_consume_token(9);
    break;
  default:
    jj_la1[59] = jj_gen;
    ;
  }
  if (a == null && comments != null)
    a = sb.makeAnnotations(comments, getContext());
  {if (true) return a;}
  throw new Error("Missing return statement in function");
}
 
Example 13
Source File: CompactSyntax.java    From openjdk-jdk9 with GNU General Public License v2.0 4 votes vote down vote up
final public Annotations Annotations() throws ParseException {
CommentList comments = getComments();
Annotations a = null;
ParsedElementAnnotation e;
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case DOCUMENTATION:
  case DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT:
    a = sb.makeAnnotations(comments, getContext());
    label_20:
    while (true) {
      e = Documentation();
                         a.addElement(e);
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case DOCUMENTATION:
      case DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT:
        ;
        break;
      default:
        jj_la1[56] = jj_gen;
        break label_20;
      }
    }
    comments = getComments();
    if (comments != null)
      a.addLeadingComment(comments);
    break;
  default:
    jj_la1[57] = jj_gen;
    ;
  }
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case 1:
    jj_consume_token(1);
       if (a == null) a = sb.makeAnnotations(comments, getContext()); clearAttributeList(); annotationsIncludeElements = false;
    label_21:
    while (true) {
      if (jj_2_7(2)) {
        ;
      } else {
        break label_21;
      }
      PrefixedAnnotationAttribute(a, false);
    }
    label_22:
    while (true) {
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case 5:
      case 6:
      case 7:
      case 10:
      case 13:
      case 14:
      case 15:
      case 16:
      case 17:
      case 18:
      case 19:
      case 26:
      case 27:
      case 31:
      case 32:
      case 33:
      case 34:
      case 35:
      case 36:
      case IDENTIFIER:
      case ESCAPED_IDENTIFIER:
      case PREFIXED_NAME:
        ;
        break;
      default:
        jj_la1[58] = jj_gen;
        break label_22;
      }
      e = AnnotationElement(false);
                                      a.addElement(e); annotationsIncludeElements = true;
    }
       a.addComment(getComments());
    jj_consume_token(9);
    break;
  default:
    jj_la1[59] = jj_gen;
    ;
  }
  if (a == null && comments != null)
    a = sb.makeAnnotations(comments, getContext());
  {if (true) return a;}
  throw new Error("Missing return statement in function");
}
 
Example 14
Source File: CompactSyntax.java    From hottub with GNU General Public License v2.0 4 votes vote down vote up
final public Annotations Annotations() throws ParseException {
CommentList comments = getComments();
Annotations a = null;
ParsedElementAnnotation e;
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case DOCUMENTATION:
  case DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT:
    a = sb.makeAnnotations(comments, getContext());
    label_20:
    while (true) {
      e = Documentation();
                         a.addElement(e);
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case DOCUMENTATION:
      case DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT:
        ;
        break;
      default:
        jj_la1[56] = jj_gen;
        break label_20;
      }
    }
    comments = getComments();
    if (comments != null)
      a.addLeadingComment(comments);
    break;
  default:
    jj_la1[57] = jj_gen;
    ;
  }
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case 1:
    jj_consume_token(1);
       if (a == null) a = sb.makeAnnotations(comments, getContext()); clearAttributeList(); annotationsIncludeElements = false;
    label_21:
    while (true) {
      if (jj_2_7(2)) {
        ;
      } else {
        break label_21;
      }
      PrefixedAnnotationAttribute(a, false);
    }
    label_22:
    while (true) {
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case 5:
      case 6:
      case 7:
      case 10:
      case 13:
      case 14:
      case 15:
      case 16:
      case 17:
      case 18:
      case 19:
      case 26:
      case 27:
      case 31:
      case 32:
      case 33:
      case 34:
      case 35:
      case 36:
      case IDENTIFIER:
      case ESCAPED_IDENTIFIER:
      case PREFIXED_NAME:
        ;
        break;
      default:
        jj_la1[58] = jj_gen;
        break label_22;
      }
      e = AnnotationElement(false);
                                      a.addElement(e); annotationsIncludeElements = true;
    }
       a.addComment(getComments());
    jj_consume_token(9);
    break;
  default:
    jj_la1[59] = jj_gen;
    ;
  }
  if (a == null && comments != null)
    a = sb.makeAnnotations(comments, getContext());
  {if (true) return a;}
  throw new Error("Missing return statement in function");
}
 
Example 15
Source File: CompactSyntax.java    From openjdk-8-source with GNU General Public License v2.0 4 votes vote down vote up
final public Annotations Annotations() throws ParseException {
CommentList comments = getComments();
Annotations a = null;
ParsedElementAnnotation e;
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case DOCUMENTATION:
  case DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT:
    a = sb.makeAnnotations(comments, getContext());
    label_20:
    while (true) {
      e = Documentation();
                         a.addElement(e);
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case DOCUMENTATION:
      case DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT:
        ;
        break;
      default:
        jj_la1[56] = jj_gen;
        break label_20;
      }
    }
    comments = getComments();
    if (comments != null)
      a.addLeadingComment(comments);
    break;
  default:
    jj_la1[57] = jj_gen;
    ;
  }
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case 1:
    jj_consume_token(1);
       if (a == null) a = sb.makeAnnotations(comments, getContext()); clearAttributeList(); annotationsIncludeElements = false;
    label_21:
    while (true) {
      if (jj_2_7(2)) {
        ;
      } else {
        break label_21;
      }
      PrefixedAnnotationAttribute(a, false);
    }
    label_22:
    while (true) {
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case 5:
      case 6:
      case 7:
      case 10:
      case 13:
      case 14:
      case 15:
      case 16:
      case 17:
      case 18:
      case 19:
      case 26:
      case 27:
      case 31:
      case 32:
      case 33:
      case 34:
      case 35:
      case 36:
      case IDENTIFIER:
      case ESCAPED_IDENTIFIER:
      case PREFIXED_NAME:
        ;
        break;
      default:
        jj_la1[58] = jj_gen;
        break label_22;
      }
      e = AnnotationElement(false);
                                      a.addElement(e); annotationsIncludeElements = true;
    }
       a.addComment(getComments());
    jj_consume_token(9);
    break;
  default:
    jj_la1[59] = jj_gen;
    ;
  }
  if (a == null && comments != null)
    a = sb.makeAnnotations(comments, getContext());
  {if (true) return a;}
  throw new Error("Missing return statement in function");
}
 
Example 16
Source File: CompactSyntax.java    From openjdk-8 with GNU General Public License v2.0 4 votes vote down vote up
final public Annotations Annotations() throws ParseException {
CommentList comments = getComments();
Annotations a = null;
ParsedElementAnnotation e;
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case DOCUMENTATION:
  case DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT:
    a = sb.makeAnnotations(comments, getContext());
    label_20:
    while (true) {
      e = Documentation();
                         a.addElement(e);
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case DOCUMENTATION:
      case DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT:
        ;
        break;
      default:
        jj_la1[56] = jj_gen;
        break label_20;
      }
    }
    comments = getComments();
    if (comments != null)
      a.addLeadingComment(comments);
    break;
  default:
    jj_la1[57] = jj_gen;
    ;
  }
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case 1:
    jj_consume_token(1);
       if (a == null) a = sb.makeAnnotations(comments, getContext()); clearAttributeList(); annotationsIncludeElements = false;
    label_21:
    while (true) {
      if (jj_2_7(2)) {
        ;
      } else {
        break label_21;
      }
      PrefixedAnnotationAttribute(a, false);
    }
    label_22:
    while (true) {
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case 5:
      case 6:
      case 7:
      case 10:
      case 13:
      case 14:
      case 15:
      case 16:
      case 17:
      case 18:
      case 19:
      case 26:
      case 27:
      case 31:
      case 32:
      case 33:
      case 34:
      case 35:
      case 36:
      case IDENTIFIER:
      case ESCAPED_IDENTIFIER:
      case PREFIXED_NAME:
        ;
        break;
      default:
        jj_la1[58] = jj_gen;
        break label_22;
      }
      e = AnnotationElement(false);
                                      a.addElement(e); annotationsIncludeElements = true;
    }
       a.addComment(getComments());
    jj_consume_token(9);
    break;
  default:
    jj_la1[59] = jj_gen;
    ;
  }
  if (a == null && comments != null)
    a = sb.makeAnnotations(comments, getContext());
  {if (true) return a;}
  throw new Error("Missing return statement in function");
}