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

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

If an instruction is recognized by the XSLT processor, it is evaluated. The standard doesn't define exactly what “recognized by the XSLT processor” means. Typically, it means that either the instruction is a vendor-specific extension implemented by that vendor, or it is a user-defined extension that has been installed or configured according to the instructions given by the vendor. It is also quite permissible for one vendor, say Oracle, to recognize extensions defined by another vendor, say Microsoft.

If an instruction is
not
recognized by the XSLT processor, the action taken by an XSLT 2.0 processor is as follows:

  • For an element in the XSLT namespace, if the effective version is
    2.0
    or less, an error is reported. If the effective version is higher than
    2.0
    , fallback processing is invoked.
  • For an extension element, fallback processing is invoked.

Similarly, an XSLT 1.0 processor invokes fallback processing when it sees an instruction in the XSLT namespace if the effective version is
2.0
(or indeed, any value other than
1.0
).

The effective version is the value of the
[xsl:]version
attribute on the nearest enclosing element that has such an attribute (the attribute must be in the XSLT namespace if the element is
not
in the XSLT namespace, and vice versa). The value is a decimal number (for example
2.3
,
10.852
, or
17
), and it is compared numerically. The idea is that a stylesheet, or a portion of a stylesheet, that uses facilities defined in some future XSLT version, 2.1 (say), should be given an effective version of
2.1
.

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

Other books

Blood and Iron by Elizabeth Bear
French Passion by Briskin, Jacqueline;
Miracle's Boys by Jacqueline Woodson
El pozo de la muerte by Lincoln Child Douglas Preston
The Rogue Prince by Michelle M. Pillow
Finding Camlann by Pidgeon, Sean