Web Service Example 6: RPC-Oriented Method with Complex Type Soap Array Parameters
First complete Web Service Example 1: RPC-Oriented Method with Simple Type Parameters. This example is an add-on.
In this example, you extend the TRAVELSERVICE web service provider with an RPC-oriented GetScheduledToursArray method that retrieves scheduled tour details for a specified destination. There can be more than one scheduled tour with a certain destination. Therefore, the Out parameter must be a complex type parameter, based on an XML schema definition, and a namespace.
The XML schema definition contains an ArrayofTours complex type that uses the SOAP encoding rules for an array. This provides a way to represent multiple elements with child elements.
Furthermore, an XSL transformation is used to transform the result of the XML export method into a document with child elements instead of attributes. For more information about this XSL transformation, refer to: Web Service Example 6: Transforming Attributes to Child Elements.