axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Simon Fell" <sf...@salesforce.com>
Subject RE: [jira] Commented: (AXIS2-520) ADB pull parser does notserialize of 0-length arrays
Date Mon, 03 Apr 2006 20:10:58 GMT
Please don't do this, if the schema says

<complexType>
<element name="foo" type="xsd:string"/>
<element name="bar" minOccurs="0" maxOccurs="unbounded" nilable="true"/>
</complexType>

then 
<x>
<foo>a</foo>
<bar xsi:nil='true'/>
</x>

Means something completely different to
<x>
<foo>a</foo>
</x>

Cheers
Simon

-----Original Message-----
From: Sanjiva Weerawarana [mailto:sanjiva@opensource.lk] 
Sent: Sunday, April 02, 2006 11:05 AM
To: axis-dev@ws.apache.org
Subject: Re: [jira] Commented: (AXIS2-520) ADB pull parser does
notserialize of 0-length arrays

On Sun, 2006-04-02 at 18:57 +0100, Eran Chinthaka (JIRA) wrote:
>     [ 
> http://issues.apache.org/jira/browse/AXIS2-520?page=comments#action_12
> 372846 ]
> 
> Eran Chinthaka commented on AXIS2-520:
> --------------------------------------
> 
> Can I know the intended behaviour for me to implement this ?

If the "array" is declared as minOccurs=1, then this should result in a
runtime fault. If its declared as nilable, then I guess it should
generate an empty element with xsi:nil=true.

Given that in general you don't have the schema around, I'd say you
should do the latter by default.

Sanjiva.

Mime
View raw message