You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beehive.apache.org by mm...@apache.org on 2004/09/17 02:27:44 UTC

svn commit: rev 46223 - in incubator/beehive/trunk/wsm: drt/tests/org/apache/beehive/wsm/jsr181/model src/runtime/org/apache/beehive/wsm/jsr181/model

Author: mmerz
Date: Thu Sep 16 17:27:43 2004
New Revision: 46223

Modified:
   incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/FooTestCase.java
   incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/Jsr181ModelTest.java
   incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/jsr181/model/WebServiceMETHODMetadata.java
Log:
Fixed the problem with @WebResult default

Contributor: Daryoush Mehrtash



Modified: incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/FooTestCase.java
==============================================================================
--- incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/FooTestCase.java	(original)
+++ incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/FooTestCase.java	Thu Sep 16 17:27:43 2004
@@ -72,7 +72,7 @@
         assertNotNull("Cannot find WebMethod goHome();", method);
         assertEquals("Invalid wmAction;", "", method.getWmAction());
         assertTrue("Cannot find @Oneway;", method.isOneWay());
-        assertNull("Unexpected @WebResult;", method.getWrName());
+        assertTrue("Unexpected @WebResult;", method.getWrName().compareTo("result") == 0);
         assertEquals("Unexpected return type;",
             void.class,
             method.getJavaReturnType()

Modified: incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/Jsr181ModelTest.java
==============================================================================
--- incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/Jsr181ModelTest.java	(original)
+++ incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/Jsr181ModelTest.java	Thu Sep 16 17:27:43 2004
@@ -343,6 +343,7 @@
                mAnnotation,  "methodname", Void.class, methodAnnotations,null);
         assertTrue(method.getWmOperationName().compareTo("methodname") == 0);
         assertTrue(method.getWmAction().length() == 0);
+        assertTrue(method.getWrName().compareTo("result") == 0);
         
     }
 

Modified: incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/jsr181/model/WebServiceMETHODMetadata.java
==============================================================================
--- incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/jsr181/model/WebServiceMETHODMetadata.java	(original)
+++ incubator/beehive/trunk/wsm/src/runtime/org/apache/beehive/wsm/jsr181/model/WebServiceMETHODMetadata.java	Thu Sep 16 17:27:43 2004
@@ -81,6 +81,7 @@
         }
         this.javaMethodName = javaMethodName;
         this.javaReturnType = javaReturnType;
+        setWrName("result");
 
         // check required parameters
         if (null == methodAnnotation) {
@@ -178,10 +179,6 @@
         if (null != annotation) {
             setWrName(annotation.name());
         }
-        if (0 == getWrName().length()) {
-            setWrName("result");
-        }
-
     }
 
     /**