axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ga...@apache.org
Subject svn commit: r701265 - in /webservices/axis2/trunk/java/modules/metadata: src/org/apache/axis2/jaxws/description/builder/converter/JavaMethodsToMDCConverter.java test/org/apache/axis2/jaxws/description/builder/converter/ReflectiveConverterTests.java
Date Thu, 02 Oct 2008 22:50:18 GMT
Author: gawor
Date: Thu Oct  2 15:50:17 2008
New Revision: 701265

URL: http://svn.apache.org/viewvc?rev=701265&view=rev
Log:
ignore private/protected methods in JavaMethodsToMDCConverter (AXIS2-4062)

Modified:
    webservices/axis2/trunk/java/modules/metadata/src/org/apache/axis2/jaxws/description/builder/converter/JavaMethodsToMDCConverter.java
    webservices/axis2/trunk/java/modules/metadata/test/org/apache/axis2/jaxws/description/builder/converter/ReflectiveConverterTests.java

Modified: webservices/axis2/trunk/java/modules/metadata/src/org/apache/axis2/jaxws/description/builder/converter/JavaMethodsToMDCConverter.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/metadata/src/org/apache/axis2/jaxws/description/builder/converter/JavaMethodsToMDCConverter.java?rev=701265&r1=701264&r2=701265&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/metadata/src/org/apache/axis2/jaxws/description/builder/converter/JavaMethodsToMDCConverter.java
(original)
+++ webservices/axis2/trunk/java/modules/metadata/src/org/apache/axis2/jaxws/description/builder/converter/JavaMethodsToMDCConverter.java
Thu Oct  2 15:50:17 2008
@@ -39,6 +39,7 @@
 import javax.xml.ws.WebEndpoint;
 import java.lang.reflect.Constructor;
 import java.lang.reflect.Method;
+import java.lang.reflect.Modifier;
 import java.lang.reflect.ParameterizedType;
 import java.lang.reflect.Type;
 import java.util.ArrayList;
@@ -58,8 +59,8 @@
     }
 
     /**
-     * This will drive the creation of a <code>MethodDescriptionComposite</code>
for every Java Method
-     * in the methods array and every Java Constructor in the constructors array.
+     * This will drive the creation of a <code>MethodDescriptionComposite</code>
for every public 
+     * Java Method in the methods array and every Java Constructor in the constructors array.
      *
      * @return - <code>List</code>
      */
@@ -67,7 +68,8 @@
         List<MethodDescriptionComposite> mdcList = new
                 ArrayList<MethodDescriptionComposite>();
         for (Method method : methods) {
-            if (!ConverterUtils.isInherited(method, declaringClass)) {
+            if (!ConverterUtils.isInherited(method, declaringClass) 
+                && Modifier.isPublic(method.getModifiers())) {
                 MethodDescriptionComposite mdc = new MethodDescriptionComposite();
                 setExceptionList(mdc, method);
                 mdc.setMethodName(method.getName());

Modified: webservices/axis2/trunk/java/modules/metadata/test/org/apache/axis2/jaxws/description/builder/converter/ReflectiveConverterTests.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/metadata/test/org/apache/axis2/jaxws/description/builder/converter/ReflectiveConverterTests.java?rev=701265&r1=701264&r2=701265&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/metadata/test/org/apache/axis2/jaxws/description/builder/converter/ReflectiveConverterTests.java
(original)
+++ webservices/axis2/trunk/java/modules/metadata/test/org/apache/axis2/jaxws/description/builder/converter/ReflectiveConverterTests.java
Thu Oct  2 15:50:17 2008
@@ -258,12 +258,14 @@
     public void doAbstract() {
     }
 
-    ;
-
     public void extraMethod() {
     }
-
-    ;
+    
+    protected void protectedChildMethod() {        
+    }
+    
+    private void privateChildMethod() {        
+    }
 }
 
 @WebService(serviceName = "InhertianceTestParent")
@@ -274,7 +276,11 @@
     public void doParentAbstract() {
     }
 
-    ;
+    protected void protectedParentMethod() {        
+    }
+    
+    private void privateParentMethod() {        
+    }
 }
 
 interface ServiceInterface {
@@ -292,7 +298,5 @@
 class AbstractService {
     public void someAbstractMethod() {
     }
-
-    ;
 }
 



Mime
View raw message