You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by sc...@apache.org on 2007/02/21 18:10:47 UTC
svn commit: r510104 - in /webservices/axis2/trunk/java/modules/jaxws:
src/org/apache/axis2/jaxws/marshaller/impl/alt/
test/org/apache/axis2/jaxws/message/ test/org/apache/axis2/jaxws/sample/
test/org/apache/axis2/jaxws/sample/dlwmin/ test/org/apache/ax...
Author: scheu
Date: Wed Feb 21 09:10:46 2007
New Revision: 510104
URL: http://svn.apache.org/viewvc?view=rev&rev=510104
Log:
AXIS2-2155
Contributor:Rich Scheuerle
More doc/lit wrapped "minimal" tests
Added:
webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/sei/TestException.java
Modified:
webservices/axis2/trunk/java/modules/jaxws/src/org/apache/axis2/jaxws/marshaller/impl/alt/LegacyExceptionUtil.java
webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/message/MessageTests.java
webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/DLWMinTests.java
webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/GreeterImpl.java
webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/META-INF/greeter.wsdl
webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/META-INF/greeterTypes.xsd
webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/META-INF/services.xml
webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/sei/Greeter.java
Modified: webservices/axis2/trunk/java/modules/jaxws/src/org/apache/axis2/jaxws/marshaller/impl/alt/LegacyExceptionUtil.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/jaxws/src/org/apache/axis2/jaxws/marshaller/impl/alt/LegacyExceptionUtil.java?view=diff&rev=510104&r1=510103&r2=510104
==============================================================================
--- webservices/axis2/trunk/java/modules/jaxws/src/org/apache/axis2/jaxws/marshaller/impl/alt/LegacyExceptionUtil.java (original)
+++ webservices/axis2/trunk/java/modules/jaxws/src/org/apache/axis2/jaxws/marshaller/impl/alt/LegacyExceptionUtil.java Wed Feb 21 09:10:46 2007
@@ -36,6 +36,7 @@
import org.apache.axis2.jaxws.ExceptionFactory;
import org.apache.axis2.jaxws.description.FaultDescription;
+import org.apache.axis2.jaxws.i18n.Messages;
import org.apache.axis2.jaxws.runtime.description.marshal.FaultBeanDesc;
import org.apache.axis2.jaxws.runtime.description.marshal.MarshalServiceRuntimeDescription;
import org.apache.axis2.jaxws.utility.ClassUtils;
@@ -110,32 +111,47 @@
// TODO Add check that faultBeanName is correct
if (log.isDebugEnabled()) {
- log.debug("Legacy Exception Bean name is = " + faultBeanName);
+ log.debug("Legacy Exception FaultBean name is = " + faultBeanName);
}
// Load the FaultBean Class
- Class faultBeanClass = MethodMarshallerUtils.loadClass(faultBeanName);
-
- // Get the properties names from the exception class
- Map<String, PropertyDescriptorPlus> pdMap = marshalDesc.getPropertyDescriptorMap(t.getClass());
-
- // We need to assign the legacy exception data to the java bean class.
- // We will use the JAXBWrapperTool.wrap utility to do this.
-
- // Get the map of child objects
- Map<String, Object> childObjects = getChildObjectsMap(t, pdMap);
-
- List<String> childNames = new ArrayList<String>(childObjects.keySet());
-
- if (log.isErrorEnabled()) {
- log.debug("List of properties on the Legacy Exception is " + childNames);
+ Class faultBeanClass = null;
+ if (faultBeanName != null && faultBeanName.length() > 0) {
+ try {
+ faultBeanClass = MethodMarshallerUtils.loadClass(faultBeanName);
+ } catch (Throwable throwable) {
+ if (log.isDebugEnabled()) {
+ log.debug("Cannot load fault bean class = " + faultBeanName + ". Fallback to using the exception object");
+ }
+ }
}
- // Use the wrapper tool to get the child objects.
- JAXBWrapperTool wrapperTool = new JAXBWrapperToolImpl();
- Map<String, PropertyDescriptorPlus> pdMapForBean = marshalDesc.getPropertyDescriptorMap(faultBeanClass);
- faultBean = wrapperTool.wrap(faultBeanClass, childNames, childObjects, pdMapForBean);
- if (log.isErrorEnabled()) {
- log.debug("Completed creation of the fault bean.");
+
+ if (faultBeanClass != null) {
+
+ // Get the properties names from the exception class
+ Map<String, PropertyDescriptorPlus> pdMap = marshalDesc.getPropertyDescriptorMap(t.getClass());
+
+ // We need to assign the legacy exception data to the java bean class.
+ // We will use the JAXBWrapperTool.wrap utility to do this.
+
+ // Get the map of child objects
+ Map<String, Object> childObjects = getChildObjectsMap(t, pdMap);
+
+ List<String> childNames = new ArrayList<String>(childObjects.keySet());
+
+ if (log.isErrorEnabled()) {
+ log.debug("List of properties on the Legacy Exception is " + childNames);
+ }
+ // Use the wrapper tool to get the child objects.
+ JAXBWrapperTool wrapperTool = new JAXBWrapperToolImpl();
+ Map<String, PropertyDescriptorPlus> pdMapForBean = marshalDesc.getPropertyDescriptorMap(faultBeanClass);
+ faultBean = wrapperTool.wrap(faultBeanClass, childNames, childObjects, pdMapForBean);
+ if (log.isErrorEnabled()) {
+ log.debug("Completed creation of the fault bean.");
+ }
+ } else {
+ throw ExceptionFactory.makeWebServiceException(Messages.getMessage("faultProcessingNotSupported",
+ "the @WebFault faultbean is missing for " + t.getClass()));
}
} catch (Exception e) {
Modified: webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/message/MessageTests.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/message/MessageTests.java?view=diff&rev=510104&r1=510103&r2=510104
==============================================================================
--- webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/message/MessageTests.java (original)
+++ webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/message/MessageTests.java Wed Feb 21 09:10:46 2007
@@ -862,6 +862,11 @@
assertTrue(persistMsg.contains("echoStringResponse"));
assertTrue(persistMsg.contains("sample return value"));
}
+
+ // After persistance: Sandesha may inspect the body. Make sure this does not cause an error
+ org.apache.axiom.soap.SOAPEnvelope env = (org.apache.axiom.soap.SOAPEnvelope) m.getAsOMElement();
+ QName qName = new QName("uri://fake", "fake");
+ env.getBody().getFirstChildWithName(qName);
}
Modified: webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/DLWMinTests.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/DLWMinTests.java?view=diff&rev=510104&r1=510103&r2=510104
==============================================================================
--- webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/DLWMinTests.java (original)
+++ webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/DLWMinTests.java Wed Feb 21 09:10:46 2007
@@ -20,9 +20,12 @@
import javax.xml.ws.BindingProvider;
import javax.xml.ws.Dispatch;
import javax.xml.ws.Service;
+import javax.xml.ws.WebServiceException;
import org.apache.axis2.jaxws.dispatch.DispatchTestConstants;
import org.apache.axis2.jaxws.sample.dlwmin.sei.Greeter;
+import org.apache.axis2.jaxws.sample.dlwmin.sei.TestException;
+import org.apache.axis2.jaxws.sample.dlwmin.types.TestBean;
import junit.framework.TestCase;
@@ -35,27 +38,20 @@
NAMESPACE, "GreeterPort");
private static final String URL_ENDPOINT = "http://localhost:8080/axis2/services/GreeterService";
- /**
- * Test that we can call the simple greetMe method
- * with style doc/lit wrapped without the presence of wrapper classes.
- */
- public void testGreetMe() {
+ private Greeter getProxy(String action) {
Service service = Service.create(QNAME_SERVICE);
Greeter proxy = service.getPort(QNAME_PORT, Greeter.class);
BindingProvider p = (BindingProvider) proxy;
p.getRequestContext().put(
BindingProvider.SOAPACTION_USE_PROPERTY, Boolean.TRUE);
p.getRequestContext().put(
- BindingProvider.SOAPACTION_URI_PROPERTY, "greetMe");
+ BindingProvider.SOAPACTION_URI_PROPERTY, action);
p.getRequestContext().put(
BindingProvider.ENDPOINT_ADDRESS_PROPERTY, URL_ENDPOINT);
-
- String me = "Scheu";
- String response = proxy.greetMe(me);
- assertTrue("Hello Scheu".equals(response));
+ return proxy;
}
- public void testGreetMe_Dispatch() {
+ private Dispatch<String> getDispatch(String action) {
// Get a dispatch
Service svc = Service.create(QNAME_SERVICE);
svc.addPort(QNAME_PORT, null, URL_ENDPOINT);
@@ -65,7 +61,30 @@
p.getRequestContext().put(
BindingProvider.SOAPACTION_USE_PROPERTY, Boolean.TRUE);
p.getRequestContext().put(
- BindingProvider.SOAPACTION_URI_PROPERTY, "greetMe");
+ BindingProvider.SOAPACTION_URI_PROPERTY, action);
+ return dispatch;
+ }
+
+ /**
+ * Test simple greetMe method
+ * with style doc/lit wrapped without the presence of wrapper classes.
+ */
+ public void testGreetMe() {
+
+ Greeter proxy = getProxy("greetMe");
+
+ String me = "Scheu";
+ String response = proxy.greetMe(me);
+ assertTrue("Hello Scheu".equals(response));
+ }
+
+ /**
+ * Test simple greetMe method with dispatch
+ * with style doc/lit wrapped without the presence of wrapper classes.
+ */
+ public void testGreetMe_Dispatch() {
+
+ Dispatch<String> dispatch = getDispatch("greetMe");
String request =
"<pre:greetMe xmlns:pre='http://apache.org/axis2/jaxws/sample/dlwmin'>" +
@@ -79,6 +98,122 @@
assertTrue(response.contains("dlwmin:greetMeResponse"));
assertTrue(response.contains(":responseType") ||
response.contains("responseType xmlns=")); // assert that response type is a qualified element
- assertTrue(!response.contains("type")); // xsi:type should not be used
+ assertTrue(!response.contains("xsi:type")); // xsi:type should not be used
}
+
+ /**
+ * Test simple greetMe method
+ * with style doc/lit wrapped without the presence of wrapper classes.
+ */
+ public void testUnqualified() {
+
+ Greeter proxy = getProxy("testUnqualified");
+
+ String request = "hello world";
+ String response = proxy.testUnqualified(request);
+ assertTrue("hello world".equals(response));
+ }
+
+ /**
+ * Test simple greetMe method with dispatch
+ * with style doc/lit wrapped without the presence of wrapper classes.
+ */
+ public void testUnqualified_Dispatch() {
+
+ Dispatch<String> dispatch = getDispatch("testUnqualified");
+
+ String request =
+ "<pre:unqualifiedTestResponse xmlns:pre='http://apache.org/axis2/jaxws/sample/dlwmin'>" +
+ "<unqualifiedRequest>hello world</unqualifiedRequest>" +
+ "</pre:unqualifiedTestResponse>";
+ System.out.println("Doc/Lit Wrapped Minimal Request =" + request);
+ String response = dispatch.invoke(request);
+ System.out.println("Doc/Lit Wrapped Minimal Response =" + response);
+
+ assertTrue(response.contains("hello world"));
+ assertTrue(response.contains("dlwmin:testUnqualifiedResponse"));
+ assertTrue(response.contains("<unqualifiedResponse")); // assert that the child element is an uqualified element
+ assertTrue(!response.contains("xsi:type")); // xsi:type should not be used
+ }
+
+ /**
+ * Test echo with complexType
+ */
+ public void testProcess_Echo() throws Exception {
+
+ Greeter proxy = getProxy("process");
+
+ TestBean request = new TestBean();
+ request.setData1("hello world");
+ request.setData2(10);
+ TestBean response = proxy.process(0, request);
+ assertTrue(response != null);
+ assertTrue(response.getData1().equals("hello world"));
+ assertTrue(response.getData2() == 10);
+ }
+
+ /**
+ * Test throwing checked exception
+ */
+ public void testProcess_CheckException() throws Exception {
+
+ Greeter proxy = getProxy("process");
+
+ TestBean request = new TestBean();
+ request.setData1("hello world");
+ request.setData2(10);
+ try {
+ TestBean response = proxy.process(1, request);
+ fail("Expected TestException thrown");
+ } catch (WebServiceException wse) {
+ // Currently there is no support if the fault bean is missing
+ assertTrue(wse.getMessage().contains("User fault processing is not supported"));
+ } catch (TestException te) {
+ assertTrue(te.getMessage().equals("TestException thrown"));
+ assertTrue(te.getFlag() == 123);
+ } catch (Exception e) {
+ fail("Expected TestException thrown but found " + e.getClass());
+ }
+ }
+
+ /**
+ * Test throwing WebServiceException
+ */
+ public void testProcess_WebServiceException() throws Exception {
+
+ Greeter proxy = getProxy("process");
+
+ TestBean request = new TestBean();
+ request.setData1("hello world");
+ request.setData2(10);
+ try {
+ TestBean response = proxy.process(2, request);
+ fail("Expected WebServiceException thrown");
+ } catch (WebServiceException wse) {
+ assertTrue(wse.getMessage().equals("WebServiceException thrown"));
+ } catch (Exception e) {
+ fail("Expected WebServiceException thrown but found " + e.getClass());
+ }
+ }
+
+ /**
+ * Test throwing NPE
+ */
+ public void testProcess_NPE() throws Exception {
+
+ Greeter proxy = getProxy("process");
+
+ TestBean request = new TestBean();
+ request.setData1("hello world");
+ request.setData2(10);
+ try {
+ TestBean response = proxy.process(3, request);
+ fail("Expected NullPointerException thrown");
+ } catch (WebServiceException wse) {
+ assertTrue(wse.getMessage().equals("NPE thrown"));
+ } catch (Exception e) {
+ fail("Expected NullPointerException thrown but found " + e.getClass());
+ }
+ }
+
}
Modified: webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/GreeterImpl.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/GreeterImpl.java?view=diff&rev=510104&r1=510103&r2=510104
==============================================================================
--- webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/GreeterImpl.java (original)
+++ webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/GreeterImpl.java Wed Feb 21 09:10:46 2007
@@ -19,7 +19,11 @@
package org.apache.axis2.jaxws.sample.dlwmin;
import org.apache.axis2.jaxws.sample.dlwmin.sei.Greeter;
+import org.apache.axis2.jaxws.sample.dlwmin.sei.TestException;
+import org.apache.axis2.jaxws.sample.dlwmin.types.TestBean;
+
import javax.jws.WebService;
+import javax.xml.ws.WebServiceException;
@WebService(endpointInterface = "org.apache.axis2.jaxws.sample.dlwmin.sei.Greeter",
targetNamespace = "http://apache.org/axis2/jaxws/sample/dlwmin")
@@ -27,6 +31,25 @@
public String greetMe(String me) {
return "Hello " + me;
+ }
+
+ public String testUnqualified(String in) {
+ return in;
+ }
+
+ public TestBean process(int inAction, TestBean in) throws TestException {
+ if (inAction == 0) {
+ // echo
+ return in;
+ } else if (inAction == 1) {
+ // throw checked exception
+ throw new TestException(123, "TestException thrown");
+ } else if (inAction == 2) {
+ throw new WebServiceException("WebServiceException thrown");
+ } else if (inAction == 3) {
+ throw new NullPointerException("NPE thrown");
+ }
+ return null;
}
}
Modified: webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/META-INF/greeter.wsdl
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/META-INF/greeter.wsdl?view=diff&rev=510104&r1=510103&r2=510104
==============================================================================
--- webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/META-INF/greeter.wsdl (original)
+++ webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/META-INF/greeter.wsdl Wed Feb 21 09:10:46 2007
@@ -25,7 +25,9 @@
targetNamespace="http://apache.org/axis2/jaxws/sample/dlwmin" name="HelloWorld">
<wsdl:types>
<schema targetNamespace="http://apache.org/axis2/jaxws/sample/dlwmin"
- xmlns="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified">
+ xmlns="http://www.w3.org/2001/XMLSchema"
+ xmlns:types="http://apache.org/axis2/jaxws/sample/dlwmin/types"
+ elementFormDefault="qualified">
<import namespace="http://apache.org/axis2/jaxws/sample/dlwmin/types"
schemaLocation="greeterTypes.xsd" />
@@ -44,6 +46,45 @@
</complexType>
</element>
+ <element name="testUnqualified">
+ <complexType>
+ <sequence>
+ <element name="unqualifiedRequest" form="unqualified" type="xsd:string"/>
+ </sequence>
+ </complexType>
+ </element>
+ <element name="testUnqualifiedResponse">
+ <complexType>
+ <sequence>
+ <element name="unqualifiedResponse" form="unqualified" type="xsd:string"/>
+ </sequence>
+ </complexType>
+ </element>
+
+ <element name="process">
+ <complexType>
+ <sequence>
+ <element name="inAction" form="unqualified" type="xsd:int"/>
+ <element name="in" form="unqualified" type="types:testBean"/>
+ </sequence>
+ </complexType>
+ </element>
+ <element name="processResponse">
+ <complexType>
+ <sequence>
+ <element name="out" form="unqualified" type="types:testBean"/>
+ </sequence>
+ </complexType>
+ </element>
+
+ <element name="processFault">
+ <complexType>
+ <sequence>
+ <element name="flag" form="unqualified" type="xsd:int"/>
+ <element name="message" form="unqualified" type="xsd:string"/>
+ </sequence>
+ </complexType>
+ </element>
</schema>
</wsdl:types>
@@ -55,6 +96,24 @@
<wsdl:message name="greetMeResponse">
<wsdl:part element="tns:greetMeResponse" name="out"/>
</wsdl:message>
+
+ <wsdl:message name="testUnqualifiedRequest">
+ <wsdl:part element="tns:testUnqualified" name="in"/>
+ </wsdl:message>
+ <wsdl:message name="testUnqualifiedResponse">
+ <wsdl:part element="tns:testUnqualifiedResponse" name="out"/>
+ </wsdl:message>
+
+ <wsdl:message name="processRequest">
+ <wsdl:part element="tns:process" name="in"/>
+ </wsdl:message>
+ <wsdl:message name="testProcessResponse">
+ <wsdl:part element="tns:processResponse" name="out"/>
+ </wsdl:message>
+ <wsdl:message name="testProcessFault">
+ <wsdl:part element="tns:processFault" name="fault"/>
+ </wsdl:message>
+
<wsdl:portType name="Greeter">
@@ -63,6 +122,17 @@
<wsdl:input message="tns:greetMeRequest" name="greetMeRequest"/>
<wsdl:output message="tns:greetMeResponse" name="greetMeResponse"/>
</wsdl:operation>
+
+ <wsdl:operation name="testUnqualified">
+ <wsdl:input message="tns:testUnqualifiedRequest" name="testUnqualifiedRequest"/>
+ <wsdl:output message="tns:testUnqualifiedResponse" name="testUnqualifiedResponse"/>
+ </wsdl:operation>
+
+ <wsdl:operation name="process">
+ <wsdl:input message="tns:processRequest" name="processRequest"/>
+ <wsdl:output message="tns:processResponse" name="processResponse"/>
+ <wsdl:fault message="tns:processFault" name="processFault"/>
+ </wsdl:operation>
</wsdl:portType>
@@ -79,6 +149,29 @@
<wsdl:output name="greetMeResponse">
<soap:body use="literal"/>
</wsdl:output>
+ </wsdl:operation>
+
+ <wsdl:operation name="testUnqualified">
+ <soap:operation soapAction="testUnqualified" style="document"/>
+ <wsdl:input name="testUnqualifiedRequest">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="testUnqualifiedResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+
+ <wsdl:operation name="process">
+ <soap:operation soapAction="process" style="document"/>
+ <wsdl:input name="processRequest">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="processResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <fault name="processFault">
+ <soap:fault name="processFault" use="literal" />
+ </fault>
</wsdl:operation>
</wsdl:binding>
Modified: webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/META-INF/greeterTypes.xsd
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/META-INF/greeterTypes.xsd?view=diff&rev=510104&r1=510103&r2=510104
==============================================================================
--- webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/META-INF/greeterTypes.xsd (original)
+++ webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/META-INF/greeterTypes.xsd Wed Feb 21 09:10:46 2007
@@ -1,7 +1,7 @@
<schema targetNamespace="http://apache.org/axis2/jaxws/sample/dlwmin/types"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified">
- <complexType name="TestBean">
+ <complexType name="testBean">
<sequence>
<element name="data1" type="xsd:string"/>
<element name="data2" type="xsd:int"/>
Modified: webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/META-INF/services.xml
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/META-INF/services.xml?view=diff&rev=510104&r1=510103&r2=510104
==============================================================================
--- webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/META-INF/services.xml (original)
+++ webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/META-INF/services.xml Wed Feb 21 09:10:46 2007
@@ -7,5 +7,11 @@
<operation name="greetMe" mep="http://www.w3.org/2004/08/wsdl/in-out">
<actionMapping/>
</operation>
+ <operation name="testUnqualified" mep="http://www.w3.org/2004/08/wsdl/in-out">
+ <actionMapping/>
+ </operation>
+ <operation name="process" mep="http://www.w3.org/2004/08/wsdl/in-out">
+ <actionMapping/>
+ </operation>
</service>
</serviceGroup>
Modified: webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/sei/Greeter.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/sei/Greeter.java?view=diff&rev=510104&r1=510103&r2=510104
==============================================================================
--- webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/sei/Greeter.java (original)
+++ webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/sei/Greeter.java Wed Feb 21 09:10:46 2007
@@ -23,6 +23,8 @@
import javax.jws.WebResult;
import javax.jws.WebService;
+import org.apache.axis2.jaxws.sample.dlwmin.types.TestBean;
+
@WebService(targetNamespace = "http://apache.org/axis2/jaxws/sample/dlwmin", name = "Greeter")
public interface Greeter {
@@ -32,4 +34,20 @@
@WebParam(targetNamespace = "http://apache.org/axis2/jaxws/sample/dlwmin", name = "requestType")
java.lang.String requestType
);
+
+ @WebResult(targetNamespace = "", partName = "unqualifiedResponse")
+ @WebMethod(operationName = "testUnqualified", action="testUnqualified")
+ public java.lang.String testUnqualified(
+ @WebParam(targetNamespace = "", partName = "unqualifiedRequest")
+ java.lang.String requestType
+ );
+
+ @WebResult(targetNamespace = "", partName = "out")
+ @WebMethod(operationName = "process", action="process")
+ public TestBean process(
+ @WebParam(targetNamespace = "", partName = "inAction")
+ int inAction,
+ @WebParam(targetNamespace = "", partName = "in")
+ TestBean in
+ ) throws TestException;
}
Added: webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/sei/TestException.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/sei/TestException.java?view=auto&rev=510104
==============================================================================
--- webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/sei/TestException.java (added)
+++ webservices/axis2/trunk/java/modules/jaxws/test/org/apache/axis2/jaxws/sample/dlwmin/sei/TestException.java Wed Feb 21 09:10:46 2007
@@ -0,0 +1,38 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.axis2.jaxws.sample.dlwmin.sei;
+
+import javax.xml.ws.WebFault;
+
+@WebFault(name="processFault", targetNamespace="http://apache.org/axis2/jaxws/sample/dlwmin")
+public class TestException extends Exception {
+
+ public int flag;
+
+
+ public TestException(int flag, String message) {
+ super(message);
+ this.flag = flag;
+ }
+
+ public int getFlag() {
+ return flag;
+ }
+
+}
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org