Subject: Re: [xsl] Understanding Identity Transformations From: Karl Stubsjoen <kstubs@xxxxxxxxx> Date: Sat, 12 Feb 2005 14:33:44 -0700 |
The things that make you say "Hmmmmm"... Thanks for speaking up... this sort of experience shared here is invaluable! Karl On Sat, 12 Feb 2005 22:21:18 +0100, Joris Gillis <roac@xxxxxxxxxx> wrote: > Tempore 21:55:30, die 02/12/2005 AD, hinc in > xsl-list@xxxxxxxxxxxxxxxxxxxxxx scripsit Karl Stubsjoen <kstubs@xxxxxxxxx>: > > > Wow.. that is easy except that I do not understand your notice > > explanation... the difference between your not( ... ) and your !=. > > "@cat != 'BLUE'": will be true if the context node has a 'cat' attribute > *and* if it has a 'cat' attribute not equal to 'BLUE'. So it's the same as > "boolean(@cat) and not(@cat='BLUE')" > > "not(@cat='BLUE')": will be true if the context node has no 'cat' > attribute *or* if it has a 'cat' attribute not equal to 'BLUE'. So it's > equal to "not(@cat) or not(@cat='BLUE')" > > Wow... so much boolean logic that it doesn't seem logical anymore... > > > So what is the difference then? I don't get it. > > The difference is that '!=' will work and 'not(...=...)' will not. > Now don't ask me why:) > The reason can probably found at http://www.w3.org/TR/xpath.html#booleans > , but I know it rather from experience than from any documentation. > > > regards, > -- > Joris Gillis (http://www.ticalc.org/cgi-bin/acct-view.cgi?userid=38041) > Gaudiam omnibus traderat W3C, nec vana fides
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Understanding Identity Tr, Joris Gillis | Thread | RE: [xsl] Understanding Identity Tr, Michael Kay |
Re: [xsl] Dynamic output method, Karl Stubsjoen | Date | RE: [xsl] Understanding Identity Tr, Michael Kay |
Month |