[Xml-compile] finding the nillable elements of a sequence type

Mark Overmeer mark at overmeer.net
Fri Oct 19 21:21:29 GMT 2012


* E R (pc88mxer at gmail.com) [121019 20:30]:
> In a <sequence> type I would like to determine which fields are
> nillable, and so I wrote the following code.

>From all the few dozen features, what is so special about nillable?

> It works for my schema, but I'm not sure if it will work for a general
> WSDL schema. Also, am I reinventing some wheels here? Any suggestions
> for making the code more general or other improvements would be
> welcome.

You could take the template() output and remove all comments which
do not contain a remark about nillable.

But probably there is also a single line XPATH expression to select
all elements with a nillable=true attribute.  I am not an XPATH
specialist.
-- 
Regards,

               MarkOv

------------------------------------------------------------------------
       Mark Overmeer MSc                                MARKOV Solutions
       Mark at Overmeer.net                          solutions at overmeer.net
http://Mark.Overmeer.net                   http://solutions.overmeer.net




More information about the Xml-compile mailing list