Subject: Re: [xsl] Universally quantified test of child attribute presence/absence From: Abel Braaksma <abel.online@xxxxxxxxx> Date: Tue, 20 Mar 2007 13:30:38 +0100 |
every $child in * satisfies $child[not(@my_attribute)]
will return true if no child has a @my_attribute that returns false. I.e., if the value were empty, but available, it would return false.
every $child in * satisfies not($child/@my_attribute)
will return true if no child has a sequence of nodes @my_attribute (alsways one or zero attribute nodes) that when normalized returns false. That is in this scenario effectively the same as above, I believe.
<child my_attribute="" /> <child my_attribute="" /> <child my_attribute="" />
will return false for the above test. And the following:
<child attribute="" /> <child attribute="" /> <child attribute="" />
will return true for the above test. And the following will return false again:
<child my_attribute="" /> <child attribute="" /> <child attribute="" />
Cheers, -- Abel
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Universally quantified te, Abel Braaksma | Thread | Re: [xsl] Universally quantified te, Yves Forkl |
Re: [xsl] Universally quantified te, David Carlisle | Date | Re: [xsl] Universally quantified te, Yves Forkl |
Month |