Hi,
Suppose i have the following in an XSD
<xsd:complexType name="Name" minOccurs="0" maxOccurs = "3">
        <xsd:sequence>
                <xsd:element name="FirstName" type="xsd:string"
minOccurs="0" maxOccurs="1">
                <xsd:element name="LastName" type="xsd:string"
minOccurs="0" maxOccurs="1">
        </xsd:sequence>
</xsd:complexType>

i.e Name itself is optional, so are the subelements within it.

I need to have name-value pairs for FirstName and LastName within the
same Name tag.
i.e. if
<Name>
        <FirstName>abc</FirstName>
        <LastName>xyz</LastName>
</Name>
<Name>
        <FirstName>pqr</FirstName>
</Name>
<Name>
        <LastName>lmn</LastName>
</Name>

I have the Document type object with me. I want 'abc and 'xyz' to be
together (say, stored in one java object) because they occur in the same
<Name> tag, but 'pqr' and 'lmn' should be separate from each other (in
different objects) because they occur in different <Name> tags.

Any pointers, how this can be done?

TIA,
abhishek.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to