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

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

. In between union operators and unary operators, there is a long list of operators with intermediate priority, such as
intersect
and
cast as
. A full list of operator priorities, showing how these operators relate to others, is given in Appendix A.

There are two division operators:
div
for exact division, and
idiv
for integer division. The precise rules for these are described below. The
mod
operator gives the remainder when one number is divided by another. The reason that the
/
symbol isn't used for division is that this would conflict with its use in path expressions, which are described in Chapter 9.

When using the minus operator, take care that it does not get confused with a hyphen within a name. If it immediately follows a name, use a space to separate it. Note that
price-discount
(without spaces) is a single hyphenated name, whereas
price

discount
(with spaces) performs a subtraction. If in doubt, use spaces to separate an operator from the surrounding tokens: it never does any harm.

Other books

Snow Shadow by Andre Norton
The Battle Begins by Devon Hughes
Time Enough for Love by Suzanne Brockmann
Tracie Peterson by Hearts Calling
Rajiv Menon -- ThunderGod by Menon, Rajiv G rtf txt html
Lone Star Renegades by Mark Wayne McGinnis
Photographs & Phantoms by Cindy Spencer Pape
Down Outback Roads by Alissa Callen