users@jaxb.java.net

Re: xsd:unsignedLong maps to BigInteger or long

From: Wolfgang Laun <wolfgang.laun_at_gmail.com>
Date: Wed, 11 Nov 2009 15:51:17 +0100

On Wed, Nov 11, 2009 at 1:36 PM, Fady <fady_at_legsem.com> wrote:
>
> Hello,
>
> I am getting a different mapping for an xsd:unsignedLong depending on the
> usage of totalDigits or maxInclusive, even though these 2 constraints should
> be equivalent.
>

> Is this the intended behavior? Shouldn't totalDigits="18" and
> maxInclusive="999999999999999999" yield the same Java type?
>

No. Yes.

This behaviour contradicts the JAXB Specification Section 6.2.2,
Atomic Datatype:
Any range limitation of an xs:integer (or derived from this), by a
total digit facet or
by limit facets, should result in the "optimized" representation int or long.

-W


> Thank you.
>
> Fady
> --
> View this message in context: http://old.nabble.com/xsd%3AunsignedLong-maps-to-BigInteger-or-long-tp26300552p26300552.html
> Sent from the java.net - jaxb users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jaxb.dev.java.net
> For additional commands, e-mail: users-help_at_jaxb.dev.java.net
>
>