Hello all,

I am working on implementing a web service specified by a WSDL and associated XSD file. One of the types in the XSD is mixed:

       <xs:complexType name="PostContent" mixed="true">
               <xs:annotation>
<xs:documentation>Type the defines the content of a post.</xs:documentation>
               </xs:annotation>
               <xs:choice minOccurs="0" maxOccurs="unbounded">
                       <xs:annotation>
<xs:documentation>This is a mixed type. It can contain one or more of each of quoted content, links to other material, and a signature block.</xs:documentation>
                       </xs:annotation>
                       <xs:element name="Link" type="xs:anyURI">
                               <xs:annotation>
<xs:documentation>A link to material external to the post.</xs:documentation>
                               </xs:annotation>
                       </xs:element>
               </xs:choice>
       </xs:complexType>

(for simplicity, I included only one of the options supported by the xs:choice). An example of this data is as follows:

                       <scild:Content>
Emmanuelm, aren't you the person who <scild:Link>http://en.wikipedia.org/w/index.php?title=Lymphoma&amp;diff=18272307&amp;oldid=15964246</scild:Link> added those other categories on 6 July 2005? --
                       </scild:Content>

I used WSDL2C to generate stubs for all the types in the XSD. However, the stubs generated for PostContent don't seem to include any way of accessing the text in the mixed type, just the elements of the choice:

       struct adb_PostContent
       {
           axutil_array_list_t* property_PostContentChoice;


               axis2_bool_t is_valid_PostContentChoice;



       };

Any idea whether this is an error in the code generator, or whether there is an underlying problem with supporting mixed content? How is mixed content represented in the Axiom types? Looking at the definition of the axiom_element struct (in om_element.c) I see only one member storing text,

axis2_char_t *text_value;

In the case of mixed nodes, is the mixed content stored in a bunch of children, which can be either text elements or nodes? Or some other method I am not seeing?

Any help you may provide will be greatly appreciated.

Thank you,


Alex Marin

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to