openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mprud...@apache.org
Subject svn commit: r443537 - /incubator/openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/event/MethodLifecycleCallbacks.java
Date Fri, 15 Sep 2006 00:51:19 GMT
Author: mprudhom
Date: Thu Sep 14 17:51:18 2006
New Revision: 443537

URL: http://svn.apache.org/viewvc?view=rev&rev=443537
Log:
Fixed error in last commit.

Modified:
    incubator/openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/event/MethodLifecycleCallbacks.java

Modified: incubator/openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/event/MethodLifecycleCallbacks.java
URL: http://svn.apache.org/viewvc/incubator/openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/event/MethodLifecycleCallbacks.java?view=diff&rev=443537&r1=443536&r2=443537
==============================================================================
--- incubator/openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/event/MethodLifecycleCallbacks.java
(original)
+++ incubator/openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/event/MethodLifecycleCallbacks.java
Thu Sep 14 17:51:18 2006
@@ -101,6 +101,9 @@
                 if (isAssignable(methods[i].getParameterTypes(), args))
                     return methods[i];
             }
+
+            return cls.getMethod(method, args);
+
         } catch (Throwable t) {
             try {
                 // try again with the declared methods, which will
@@ -115,10 +118,6 @@
                         args == null ? null : Arrays.asList(args)), t);
             }
 		}
-
-        throw new UserException(_loc.get("method-notfound",
-            cls.getName(), method,
-                args == null ? null : Arrays.asList(args)));
 	}
 
     /** 
@@ -133,7 +132,7 @@
             return false;
 
         for (int i = 0; i < from.length; i++) {
-            if (from[i] == null || !from[i].isAssignableFrom(to[i]))
+            if (from[i] != null && !from[i].isAssignableFrom(to[i]))
                 return false;
         }
 



Mime
View raw message