Does XmlBeans guarantee that the Java enumerations it creates for XML
enumerations:

1.  Are sequentially numbered, using the same order in the WSDL
2.  Start with index 0 (or 1)
3.  The toString() of the resulting Java enum yields the exact string used
in the WSDL enum

These seem like logical assumptions but they are not explicitly stated as
far as I can tell.  We need to convert the enums from the WSDL Java
classes to business domain Java object enums.  Sometimes these are "real"
enums in JDK 1.4 using ValuedEnum, so we'd like to use the string
representation to convert back and forth.  Sometimes we have domain enums
in the form of public static ints, so we want to know if we can use a
simple conversion of the integer value or need a big switch statement.

Any help is much appreciated.  Ideally it'd be nice to have a pointer to
official documentation... I know I can run the code and see what happens,
but that's not very reassuring that it won't change without official docs
saying that's part of the XmlBeans contract.

Raul
http://www.cantara.com

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

Reply via email to