I tried to run SourceGenerator against some of our XSDs and found the
xsd:integer is mapped to java.lang.Integer which can cause an overrun.
Take this simple example og a credit card nr type:
<xsd:simpleType name="CreditCardNr" id="CreditCardNr">
<xsd:restriction base="xsd:integer">
<xsd:minInclusive value="1000000000000"/>
<xsd:totalDigits value="16"/>
</xsd:restriction>
</xsd:simpleType>
SourceGenerator gives me:
Exception in thread "main" java.lang.NumberFormatException: 1000000000000
at java.lang.Integer.parseInt(Integer.java:417)
at java.lang.Integer.parseInt(Integer.java:454)
at org.exolab.castor.xml.schema.Facet.toInt(Facet.java:144)
I think xsd:integer should be mapped to java.math.BigDecimal, at least if
one of the restrictions is outside the range of a java int ?!
Regards,
Bernhard
-----------------------------------------------------------
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
unsubscribe castor-dev