users@jaxb.java.net

Re: Boolean 0 or 1 true or false

From: Wolfgang Laun <wolfgang.laun_at_gmail.com>
Date: Fri, 6 Nov 2009 10:48:16 +0100

Both. See http://www.w3.org/TR/xmlschema-2/#boolean
-W

On Fri, Nov 6, 2009 at 10:09 AM, Lulseged Zerfu <lulseged.zerfu_at_ericsson.com
> wrote:

> Hi
>
> We use jaxb to merge to xml files to one and see that 0's are changed to
> false and 1's are changed to true in the output.
>
> In the xsd file we have the following declaration:
>
> <xs:element name="enableAM" type="xs:boolean" default="false"
> minOccurs="0">
> <xs:annotation>
> <xs:documentation>Use to configure saAmfCompAMEnable mib
> object.</xs:documentation>
> </xs:annotation>
> </xs:element>
>
> In put <enableAM>0</enableAM> is output to <enableAM>false</enableAM> and
> <enableAM>1</enableAM> is output to <enableAM>true</enableAM>.
>
> The xml document looks valid. JAXB never complains about 0's an 1's. Gives
> output.
>
> What is correct?
>
> Lulseged
>
>