users@jaxb.java.net

Re: sequence element order

From: Ryan Shoemaker - JavaSoft East <Ryan.Shoemaker_at_Sun.COM>
Date: Fri, 11 Feb 2005 16:02:03 -0500

Jimmy Han wrote:
> Hi,
>
> Is there a way for Java applications to get the order
> of sequence elements? For example,
>
> <xsd:complexType name="MyObject">
> <xsd:sequence>
> <xsd:element name="A" type="xsd:string"/>
> <xsd:element name="B" type="xsd:string"/>
> </...
> </...
>
> How can I know that A is before B using the generated classes?
>

You can't. In general, we don't expose much of the schema
at all - things like min/maxOccurs, min/maxInclusive, etc.

Can you explain why you need this information?

Thanks,

--Ryan