aspose file tools*
The moose likes Web Services and the fly likes How to find Document style or RPC from SOAP Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » Web Services
Bookmark "How to find Document style or RPC from SOAP" Watch "How to find Document style or RPC from SOAP" New topic
Author

How to find Document style or RPC from SOAP

satya ganesh
Greenhorn

Joined: Jul 14, 2008
Posts: 7
In SOAP message, I believe its not possible to mention whether its a Document style or RPC..

Is it Possible to figure out whether it is a Document style or RPC style of messaging only by looking at the SOAP message?
Ivan Krizsan
Ranch Hand

Joined: Oct 04, 2006
Posts: 2198
    
    1
Hi!
In a document style SOAP message that follows the WS-I Basic Profile, the SOAP body may only contain one XML fragment.
This XML fragment can be validated in its entirety, which means that the root element of the fragment belongs to some namespace.
With RPC style, the root element will be an element which corresponds to the name of the operation invoked and parameters to the operation, which are sub-elements of the root element, will thus be inside this element.
The root element in an RPC request is not described in the WSDL and need thus not belong to the same namespace as the parameters to the RPC operation.
So, at least in theory, it should be possible to tell the difference between a Document style and a RPC style SOAP message by looking at the namespace of the root element of the payload of the SOAP message.
Hope this helps and that I got this message right, writing it in a hurry!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to find Document style or RPC from SOAP