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
5.06Mb 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

Blue Genes by Val McDermid
Behind His Lens by R. S. Grey
Our Lady of the Forest by David Guterson
Vexed by Phoenyx Slaughter
Taken by Surprise by Tonya Ramagos
Kissing in the Dark by Wendy Lindstrom