]> source.dussan.org Git - aspectj.git/commitdiff
238992: test and fix
authoraclement <aclement>
Mon, 7 Jul 2008 22:32:37 +0000 (22:32 +0000)
committeraclement <aclement>
Mon, 7 Jul 2008 22:32:37 +0000 (22:32 +0000)
weaver/src/org/aspectj/weaver/ReferenceType.java

index 782a5dc04457501d6e61aa6fd2bb4751f2c9fe64..aab1bfa2303ff5400751cc3846b156457c54344d 100644 (file)
@@ -156,7 +156,18 @@ public class ReferenceType extends ResolvedType {
        return delegate.getAnnotationTypes(); 
     }
     
-    public boolean isAspect() {
+       public AnnotationX getAnnotationOfType(UnresolvedType ofType) {
+               AnnotationX[] axs = delegate.getAnnotations();
+               if (axs==null) return null;
+               for (int i=0;i<axs.length;i++) {
+                       if (axs[i].getSignature().equals(ofType)) {
+                               return axs[i];
+                       }
+               }
+               return null;
+       }
+
+       public boolean isAspect() {
        return delegate.isAspect();
     }