users@jaxb.java.net

Re: JAXB 2.0 xs:int binding

From: Kohsuke Kawaguchi <Kohsuke.Kawaguchi_at_Sun.COM>
Date: Fri, 31 Mar 2006 11:54:22 -0800

Kasia Trapszo wrote:
> I noticed when an xs:int type attribute is required the default binding
> results in a primitive int type, if it's optional, result is an Integer
> object.

That's the intended behavior, so that you can check for non-existent
attribute.

JDK 5.0 autoboxing should let you convert between them without worrying
too much.

-- 
Kohsuke Kawaguchi
Sun Microsystems                   kohsuke.kawaguchi_at_sun.com