geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject svn commit: r534273 - /geronimo/server/trunk/modules/geronimo-j2ee-builder/src/main/java/org/apache/geronimo/j2ee/deployment/annotation/EJBAnnotationHelper.java
Date Tue, 01 May 2007 23:22:36 GMT
Author: dain
Date: Tue May  1 16:22:35 2007
New Revision: 534273

URL: http://svn.apache.org/viewvc?view=rev&rev=534273
Log:
Properly detect ejb interface

Modified:
    geronimo/server/trunk/modules/geronimo-j2ee-builder/src/main/java/org/apache/geronimo/j2ee/deployment/annotation/EJBAnnotationHelper.java

Modified: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/main/java/org/apache/geronimo/j2ee/deployment/annotation/EJBAnnotationHelper.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/main/java/org/apache/geronimo/j2ee/deployment/annotation/EJBAnnotationHelper.java?view=diff&rev=534273&r1=534272&r2=534273
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/main/java/org/apache/geronimo/j2ee/deployment/annotation/EJBAnnotationHelper.java
(original)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/main/java/org/apache/geronimo/j2ee/deployment/annotation/EJBAnnotationHelper.java
Tue May  1 16:22:35 2007
@@ -232,8 +232,20 @@
         // they are optional in EJB 3.0)
         if (interfce != null && !interfce.equals(Object.class)) {
             if (EJBHome.class.isAssignableFrom(interfce)) {
+                for (Method m : interfce.getMethods()) {
+                    if (m.getName().startsWith("create")) {
+                        interfce = m.getReturnType();
+                        break;
+                    }
+                }
                 remoteFlag = true;
             } else if (EJBLocalHome.class.isAssignableFrom(interfce)) {
+                for (Method m : interfce.getMethods()) {
+                    if (m.getName().startsWith("create")) {
+                        interfce = m.getReturnType();
+                        break;
+                    }
+                }
                 localFlag = true;
             } else {
                 if (interfce.getAnnotation(Local.class) != null) {



Mime
View raw message