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
10.01Mb 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 Bicycle Thief by Franklin W. Dixon
Wildwood by Drusilla Campbell
Dogma by Lars Iyer
The Da Vinci Code by Dan Brown
Verse by Moses Roth
Five Minutes in Heaven by Lisa Alther