XSLT 2.0 and XPath 2.0 Programmer's Reference, 4th Edition (357 page)

BOOK: XSLT 2.0 and XPath 2.0 Programmer's Reference, 4th Edition
8.77Mb size Format: txt, pdf, ePub

The syntax for these operators has already been given, because they are combined into the same production rules as the simpler operators
eq
,
ne
,
lt
,
le
,
gt
, and
ge
, which are given on page 582.

General comparisons are more powerful than value comparisons in two ways:

  • General comparisons allow either or both operands to be sequences (of zero, one, or many items), whereas value comparisons require the operands to be single items.
  • General comparisons are more flexible in the way they handle untyped atomic values (that is, data from schema-less documents). In particular, the way an untyped value is handled depends on the type of the value that it is being compared with.

In addition, general comparisons have special rules for use when backward-compatibility mode is selected (in XSLT, this applies when the
version
attribute is set to
1.0
).

Other books

The Towers of Love by Birmingham, Stephen;
Sweeter Than Honey by Mary B. Morrison
Fudging the Books by Daryl Wood Gerber
And Then There Were None by Agatha Christie
Paradise Lodge by Nina Stibbe
Suspicious Activities by Tyler Anne Snell
In the Forest by Edna O'Brien
Adopted Son by Dominic Peloso