src/share/classes/com/sun/tools/javac/code/Symbol.java

changeset 1491
9f42a06a49c0
parent 1473
31780dd06ec7
child 1513
cf84b07a82db
     1.1 --- a/src/share/classes/com/sun/tools/javac/code/Symbol.java	Thu Jan 10 19:38:57 2013 -0800
     1.2 +++ b/src/share/classes/com/sun/tools/javac/code/Symbol.java	Mon Jan 14 19:52:36 2013 +0100
     1.3 @@ -1,5 +1,5 @@
     1.4  /*
     1.5 - * Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
     1.6 + * Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
     1.7   * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     1.8   *
     1.9   * This code is free software; you can redistribute it and/or modify it
    1.10 @@ -450,7 +450,7 @@
    1.11       * This is the implementation for {@code
    1.12       * javax.lang.model.element.Element.getAnnotationMirrors()}.
    1.13       */
    1.14 -    public final List<Attribute.Compound> getAnnotationMirrors() {
    1.15 +    public final List<? extends AnnotationMirror> getAnnotationMirrors() {
    1.16          return getRawAttributes();
    1.17      }
    1.18  
    1.19 @@ -462,6 +462,11 @@
    1.20          return JavacElements.getAnnotation(this, annoType);
    1.21      }
    1.22  
    1.23 +    // This method is part of the javax.lang.model API, do not use this in javac code.
    1.24 +    public <A extends java.lang.annotation.Annotation> A[] getAnnotations(Class<A> annoType) {
    1.25 +        return JavacElements.getAnnotations(this, annoType);
    1.26 +    }
    1.27 +
    1.28      // TODO: getEnclosedElements should return a javac List, fix in FilteredMemberList
    1.29      public java.util.List<Symbol> getEnclosedElements() {
    1.30          return List.nil();

mercurial