|
FW: Map specific names to enum classes: msg#00103text.xml.xmlbeans.user
Is there a way to
include non-English characters in an enumerated class? I have a schema
which contains a restriction that has non-English
characters:
...
<xs:simpleType
name="unit_list">
<xs:restriction base="xs:string"> <xs:enumeration value="µM"/> <xs:enumeration value="nmol/min/ml"/> <xs:enumeration value="µg/L"/> ... </xs:restriction> </xs:simpleType> (if your browser
isn't set to UTF-8, the greek letter "mu" is in the enumerated
list)
When scomp tries to translate
it, it throws an error from the Java compiler that suggests it doesn't like the
names that were automatically assigned:
C:\...\Temp\xbean18211.d\src\noNamespace\UnitList.java:210:
';' expected
static final int INT_?_U_ML = 51; ^ To fix this, I
thought perhaps I could assign specific names to the enumeration, telling it how
to name those classes and avoid the mu's. I've taken a look at the example
in the FAQ on how to map specific element/attribute names to java names, but I
don't really see how to do the same thing for the constants assigned to an
enumeration. I did tried playing with it but I don't think scomp
likes the mu's in the .xsdconfig file:
C:\code\plasmaConfig.xsdconfig:1: error: Character
conversion error: "Unconvertible UTF-8 character beginning with 0xb5" (line
number may be too low).
Time to build schema type system: 1.051 seconds BUILD FAILED Does anyone know if
there is a way to include these non-English characters in my
enumeration?
Thanks,
Anne
Marie
------------------------------
Anne Marie Simmie Bioinformatics Associate
Scientist Scientific
Computing Protana Inc. Toronto, Ontario, Canada |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | RE: Does XMLBeans expose annotation and appinfo elements?: 00103, Radu Preotiuc-Pietro |
|---|---|
| Next by Date: | German Umlauts and other special characters: 00103, Cordes, Hans-Dieter |
| Previous by Thread: | Does XMLBeans expose annotation and appinfo elements?i: 00103, Jim McMaster |
| Next by Thread: | German Umlauts and other special characters: 00103, Cordes, Hans-Dieter |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |