[xsd-users] C++/Hybrid , xsi:nil

dd ddd dkodko at yahoo.com
Thu Apr 9 13:36:11 EDT 2009


Boris,
would you be able to comment on the below 2 questions, please...
1. what would be the timeline for adopting/implementing C++/Serializer, C++/Hybrid approaches to XSD (since XSDe already has it released)  http://www.codesynthesis.com/projects/xsd/documentation/future.xhtml
2. regarding nillable and xsi:nil  i did trace several discussions and i believe there are substential grounds for having nillable/xsi:nil implemented in the core templates, although i understand there is a fairly simple work around with customization approach as you outlined herehttp://www.codesynthesis.com/pipermail/xsd-users/2007-June/001070.html
    a. my understanding that if element is defined with nillable="true" and xml produced contains empty element without xsi:nil="true" it should fail full schema validation (btw, for Xerces parsing wrapper implementation in XSD fgXercesSchemaFullChecking is always explicitly turned off, which i think may be also left configurable through xsd::cxx::tree::flags for example), although xs:string without facets is an exceptional case here (XMLSpy and JAXB2.0 for example interpret it that way, i.e. <element name="a" type="xs:int" nillable="true"/> producing  <a/> is invalid, where <a xsi:nil="true"/> is valid)    http://www.w3.org/TR/xmlschema-1/#xsi_nil      b. with regards to practical application this feature is pretty handy when for example need to indicate the elements to be deleted let's say from database when having schemas exposed as API contracts/webservices (more so in case of complexType entities), instead of introducing custom
 mechanisms to indicate that

cheers,
dmitry


      


More information about the xsd-users mailing list