diff options
author | chiba <chiba@30ef5769-5b8d-40dd-aea6-55b5d6557bb3> | 2013-03-26 16:46:17 +0000 |
---|---|---|
committer | chiba <chiba@30ef5769-5b8d-40dd-aea6-55b5d6557bb3> | 2013-03-26 16:46:17 +0000 |
commit | fba928ea9f16486ad07c9f48fbc7c021ca5535a9 (patch) | |
tree | a0c069e2092c7248ae3d25f0bc4816b6d28f3eee /src/main/javassist/util | |
parent | 7ff52ac61b307d6a785ae458d06bdf52335ae79c (diff) | |
download | javassist-fba928ea9f16486ad07c9f48fbc7c021ca5535a9.tar.gz javassist-fba928ea9f16486ad07c9f48fbc7c021ca5535a9.zip |
fixed JASSIST-183
git-svn-id: http://anonsvn.jboss.org/repos/javassist/trunk@700 30ef5769-5b8d-40dd-aea6-55b5d6557bb3
Diffstat (limited to 'src/main/javassist/util')
-rw-r--r-- | src/main/javassist/util/proxy/RuntimeSupport.java | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/src/main/javassist/util/proxy/RuntimeSupport.java b/src/main/javassist/util/proxy/RuntimeSupport.java index 4c5d8996..8c8425f7 100644 --- a/src/main/javassist/util/proxy/RuntimeSupport.java +++ b/src/main/javassist/util/proxy/RuntimeSupport.java @@ -52,7 +52,7 @@ public class RuntimeSupport { { methods[index + 1] = thisMethod == null ? null : findMethod(clazz, thisMethod, desc); - methods[index] = findSuperMethod(clazz, superMethod, desc); + methods[index] = findSuperClassMethod(clazz, superMethod, desc); } /** @@ -75,7 +75,19 @@ public class RuntimeSupport { * * @throws RuntimeException if the method is not found. */ - public static Method findSuperMethod(Class clazz, String name, String desc) { + public static Method findSuperMethod(Object self, String name, String desc) { + // for JBoss Seam. See JASSIST-183. + Class clazz = self.getClass(); + return findSuperClassMethod(clazz, name, desc); + } + + /** + * Finds a method that has the given name and descriptor and is declared + * in the super class. + * + * @throws RuntimeException if the method is not found. + */ + public static Method findSuperClassMethod(Class clazz, String name, String desc) { Method m = findSuperMethod2(clazz.getSuperclass(), name, desc); if (m == null) m = searchInterfaces(clazz, name, desc); |