]> source.dussan.org Git - aspectj.git/commitdiff
generics
authoraclement <aclement>
Sat, 7 Nov 2009 00:23:47 +0000 (00:23 +0000)
committeraclement <aclement>
Sat, 7 Nov 2009 00:23:47 +0000 (00:23 +0000)
org.aspectj.matcher/src/org/aspectj/weaver/patterns/DeclareAnnotation.java

index 3f8a01e6957cfb97ef7470e27cbe7f1c77810ec2..94c55c25115718b2433f1505828c1a47a46851ae 100644 (file)
@@ -326,8 +326,8 @@ public class DeclareAnnotation extends Declare {
                if (annotation != null) {
                        return;
                }
-               for (Iterator iter = containingAspect.getMethods(); iter.hasNext();) {
-                       ResolvedMember member = (ResolvedMember) iter.next();
+               for (Iterator<ResolvedMember> iter = containingAspect.getMethods(false); iter.hasNext();) {
+                       ResolvedMember member = iter.next();
                        if (member.getName().equals(annotationMethod)) {
                                AnnotationAJ[] annos = member.getAnnotations();
                                if (annos == null) {
@@ -388,8 +388,8 @@ public class DeclareAnnotation extends Declare {
         */
        public ResolvedType getAnnotationType() {
                if (annotationType == null) {
-                       for (Iterator iter = containingAspect.getMethods(); iter.hasNext();) {
-                               ResolvedMember member = (ResolvedMember) iter.next();
+                       for (Iterator<ResolvedMember> iter = containingAspect.getMethods(false); iter.hasNext();) {
+                               ResolvedMember member = iter.next();
                                if (member.getName().equals(annotationMethod)) {
                                        ResolvedType[] annoTypes = member.getAnnotationTypes();
                                        if (annoTypes == null) {