Richard Quadling
asked on
XPath / XQuery issue with selecting nodes NOT containing a value.
Trying to xinclude content.
This is the data (it is a list of properties to a class) ...
<classsynopsisinfo role="comment">&Properties ;</classsy nopsisinfo >
<fieldsynopsis>
<modifier>protected</modif ier>
<type>string</type>
<varname linkend="exception.props.m essage">me ssage</var name>
</fieldsynopsis>
<fieldsynopsis>
<modifier>private</modifie r>
<type>string</type>
<varname linkend="exception.props.s tring">str ing</varna me>
</fieldsynopsis>
<fieldsynopsis>
<modifier>protected</modif ier>
<type>int</type>
<varname linkend="exception.props.c ode">code< /varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>protected</modif ier>
<type>string</type>
<varname linkend="exception.props.f ile">file< /varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>protected</modif ier>
<type>int</type>
<varname linkend="exception.props.l ine">line< /varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>private</modifie r>
<type>array</type>
<varname linkend="exception.props.t race">trac e</varname >
</fieldsynopsis>
I now want to document a sub-class. In the sub-class private properties are not to be shown.
To include all the properties, the following tag works just fine.
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.excepti on')/desce ndant::db: fieldsynop sis" />
What I want to do is exclude nodes which have a <modifier>private</modifie r> sub-node.
I thought the following would work, but it doesn't.
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.excepti on')/desce ndant::db: fieldsynop sis[modifi er!=privat e]" />
I also need to extend the same logic to ...
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.excepti on')/db:re fentry/db: refsect1[@ role='desc ription']/ descendant ::db:metho dsynopsis) " />
In both cases, I'm getting the private properties/methods and I want to exclude them.
Any ideas?
Regards,
Richard.
This is the data (it is a list of properties to a class) ...
<classsynopsisinfo role="comment">&Properties
<fieldsynopsis>
<modifier>protected</modif
<type>string</type>
<varname linkend="exception.props.m
</fieldsynopsis>
<fieldsynopsis>
<modifier>private</modifie
<type>string</type>
<varname linkend="exception.props.s
</fieldsynopsis>
<fieldsynopsis>
<modifier>protected</modif
<type>int</type>
<varname linkend="exception.props.c
</fieldsynopsis>
<fieldsynopsis>
<modifier>protected</modif
<type>string</type>
<varname linkend="exception.props.f
</fieldsynopsis>
<fieldsynopsis>
<modifier>protected</modif
<type>int</type>
<varname linkend="exception.props.l
</fieldsynopsis>
<fieldsynopsis>
<modifier>private</modifie
<type>array</type>
<varname linkend="exception.props.t
</fieldsynopsis>
I now want to document a sub-class. In the sub-class private properties are not to be shown.
To include all the properties, the following tag works just fine.
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.excepti
What I want to do is exclude nodes which have a <modifier>private</modifie
I thought the following would work, but it doesn't.
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.excepti
I also need to extend the same logic to ...
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.excepti
In both cases, I'm getting the private properties/methods and I want to exclude them.
Any ideas?
Regards,
Richard.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.excepti