JBoss development,
A new message was posted in the thread "Regression moving to JBossXB
2.0.2.Beta5":
http://community.jboss.org/message/532711#532711
Author : Alexey Loubyansky
Profile :
http://community.jboss.org/people/alex.loubyansky@jboss.com
Message:
--------------------------------------------------------------
The problem is the root element in your testcase is not nillable. If I change the element
declaration above to
<xsd:element name='root' nillable='false'>
the nil attribute will be ignored during unmarshalling.
The root element creation happens in
http://anonsvn.jboss.org/repos/jbossws/stack/native/trunk/modules/core/sr...
method bindParameterToElement(SchemaBinding schemaBinding, QName xmlName, QName xmlType)
The line is schemaBinding.addElement(xmlName, typeBinding);
This will create and return newly created root element. But it's not made nillable by
default. Which kind of makes sense as the default, since by default nillable in XSD and
binding annotations is false.
Can you consider adding a line there to make it nillable? E.g.
ElementBinding e = schemaBinding.addElement(xmlName, typeBinding);
e.setNillable(true);
--------------------------------------------------------------
To reply to this message visit the message page:
http://community.jboss.org/message/532711#532711