0 Replies Latest reply on Feb 21, 2007 11:06 PM by ajitp

    WebService serialization- extended type in schema

    ajitp
      I am using the WebService class to get data using SOAP froma web service implementation. The WSDL and XSD schema for the web service defines a "get" API for an "filter" object that is of type BaseClass. Specific objects that can be retrieved (e.g., UserAccount, Session) are defined as extensions to this BaseClass.

      When making the SOAP request using Java Axis the procedure is to create an object of type UserAccount- which class is generated by Axis from the WSDL/XSD files.

      How can I make the request using Flex? In my AS code I can create an object called "filter" and the XML is generated as:
      <getRequest>
      <filter/>
      </getRequest>

      But how can I set filter to one of the derived class. In other words, the desired XML should be:
      <getRequest>
      <filter xsi:type="UserAccount"/>
      </getRequest>

      The only workaround I have found is to handcraft the XML requests (format="xml") but I would like to use the power of working with objects as opposed to XML nodes.