deltaspike-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tandrasc...@apache.org
Subject [1/2] deltaspike git commit: DELTASPIKE-823 fixed ProxyUtils interface proxy handling
Date Sat, 14 Feb 2015 11:06:45 GMT
Repository: deltaspike
Updated Branches:
  refs/heads/master e0d22a042 -> bf7fe6085


DELTASPIKE-823 fixed ProxyUtils interface proxy handling

Project: http://git-wip-us.apache.org/repos/asf/deltaspike/repo
Commit: http://git-wip-us.apache.org/repos/asf/deltaspike/commit/20dde8fa
Tree: http://git-wip-us.apache.org/repos/asf/deltaspike/tree/20dde8fa
Diff: http://git-wip-us.apache.org/repos/asf/deltaspike/diff/20dde8fa

Branch: refs/heads/master
Commit: 20dde8faf36bb506c47d5da02082bddbe215a758
Parents: e0d22a0
Author: Thomas Andraschko <tandraschko@apache.org>
Authored: Sat Feb 14 12:05:17 2015 +0100
Committer: Thomas Andraschko <tandraschko@apache.org>
Committed: Sat Feb 14 12:05:17 2015 +0100

----------------------------------------------------------------------
 .../org/apache/deltaspike/core/util/ProxyUtils.java     | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/deltaspike/blob/20dde8fa/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/util/ProxyUtils.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/util/ProxyUtils.java
b/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/util/ProxyUtils.java
index 03e9f06..158207a 100644
--- a/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/util/ProxyUtils.java
+++ b/deltaspike/core/api/src/main/java/org/apache/deltaspike/core/util/ProxyUtils.java
@@ -74,7 +74,13 @@ public abstract class ProxyUtils
         
         if (isInterfaceProxy(proxyClass))
         {
-            result.addAll(Arrays.asList(proxyClass.getInterfaces()));
+            for (Class<?> currentInterface : proxyClass.getInterfaces())
+            {
+                if (proxyClass.getName().startsWith(iface.getName()))
+                {
+                    result.add(currentInterface);
+                }
+            }
         }
         else
         {
@@ -101,9 +107,9 @@ public abstract class ProxyUtils
         
         if (proxyClass.getName().contains("$$"))
         {
-            for (Class<?> iface : interfaces)
+            for (Class<?> currentInterface : interfaces)
             {
-                if (proxyClass.getName().startsWith(iface.getName()))
+                if (proxyClass.getName().startsWith(currentInterface.getName()))
                 {
                     return true;
                 }


Mime
View raw message