|
What's wrong?
Service descriptor: <isd:service xmlns:isd="http://xml.apache.org/xml-soap/deployment" id="urn:test-service"> <isd:provider type="java" scope="Application" methods="createOrder" > <isd:java class="TestService" static="false" /> </isd:provider>
<isd:faultListener>org.apache.soap.server.DOMFaultListener</isd:faultListener> </isd:service>
Here's the service look like:
public String createOrder(Element orderReq) { // check input params if( orderReq == null) { throw new IllegalArgumentException("The orderReq cannot be null."); }
// process order boolean ret = processor.process(orderReq); if(ret) return "1"; else return "0"; }
Here's the client calling the service: DocumentBuilder builder = XMLParserUtils.getXMLDocBuilder(); Document doc = builder.parse(new FileInputStream(xmlFile));
// Build the Call object Call call = new Call(); call.setTargetObjectURI("urn:test-service"); call.setMethodName("createOrder"); call.setEncodingStyleURI(Constants.NS_URI_LITERAL_XML);
// Set up parameters Vector params = new Vector(); params.addElement(new Parameter("orderReq", Element.class, doc.getDocumentElement(), Constants.NS_URI_LITERAL_XML)); call.setParams(params);
// Invoke the call Response response; response = call.invoke(url, ""); Regards, -----Original Message-----
What does your code look like? It appears that you are trying to pass something other than an Element type to your service?
Miguel
|
Title: How to pass Element argument
- How to pass Element argument Yong Miao
- RE: How to pass Element argument Miguel Perez
- Unsubscribe me akshay saluja
- RE: How to pass Element argument Yong Miao
- RE: How to pass Element argument Miguel Perez
- RE: How to pass Element argument Yong Miao
- RE: How to pass Element argument Miguel Perez
- RE: How to pass Element argument bryan . hsu
- RE: How to pass Element argument Yong Miao
- RE: How to pass Element argument bryan . hsu
- RE: How to pass Element argument Yong Miao
- How to send and receive array and ar... Indrasish N Basuroychowdhury
