108
Handling XML Documents in a Web Service
name="PurchaseOrderService_submitPurchaseOrderResponse">
parameterOrder="PurchaseOrderXMLDoc">
message="tns:PurchaseOrderService_submitPurchaseOrder"/>
"tns:PurchaseOrderService_submitPurchaseOrderResponse"/>
...
Code Example 3.17
Mapping XML Document to 
xsd:string
Code Example 3.18 shows the equivalent Java interface for the WSDL shown
in Code Example 3.17.
public interface PurchaseOrderService extends Remote {
public String submitPurchaseOrder(String poDocument) 
throws RemoteException, InvalidOrderException;
}
Code Example 3.18
Receiving an XML Document as a 
String
 object
If you are developing your service using the Java to WSDL approach, and the
service must exchange XML documents and be interoperable with clients on any
platform, then passing documents as 
String
 objects may be your only option.
<





New Page 1









Web Hosting Apache