aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoracolyer <acolyer>2005-08-21 19:44:28 +0000
committeracolyer <acolyer>2005-08-21 19:44:28 +0000
commit78f6eed899449f59a5893d0190081244422067f7 (patch)
treeb408389fc18c7a3d101d78c7909215ba5367b783
parentb0622ad2495f6bd3744751c9e52375f4b5601114 (diff)
downloadaspectj-78f6eed899449f59a5893d0190081244422067f7.tar.gz
aspectj-78f6eed899449f59a5893d0190081244422067f7.zip
added new method, methods() which returns all methods of a type, including itd'd ones
-rw-r--r--org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/lookup/InterTypeMemberFinder.java14
1 files changed, 13 insertions, 1 deletions
diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/lookup/InterTypeMemberFinder.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/lookup/InterTypeMemberFinder.java
index 377ef20d7..d7744e864 100644
--- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/lookup/InterTypeMemberFinder.java
+++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/lookup/InterTypeMemberFinder.java
@@ -354,7 +354,19 @@ public class InterTypeMemberFinder implements IMemberFinder {
// return m2.declaringClass;
// }
-
+ public MethodBinding[] methods(SourceTypeBinding sourceTypeBinding) {
+ MethodBinding[] orig = sourceTypeBinding.methods();
+ if (interTypeMethods.isEmpty()) return orig;
+
+ List ret = new ArrayList(Arrays.asList(orig));
+ for (int i=0, len=interTypeMethods.size(); i < len; i++) {
+ MethodBinding method = (MethodBinding)interTypeMethods.get(i);
+ ret.add(method);
+ }
+
+ if (ret.isEmpty()) return SourceTypeBinding.NoMethods;
+ return (MethodBinding[])ret.toArray(new MethodBinding[ret.size()]);
+ }
//XXX conflicts
public MethodBinding[] getMethods(