Deepx Xml Path Language Quick Reference Page 2

ADVERTISEMENT

boolean contains(string, string)
§ 4.2
an object of a type other than the four basic types is converted to a
boolean in a way that is dependent on that type.
The contains function returns true if the first argument string contains the
second argument string, and otherwise returns false.
boolean false()
§ 4.3
string normalize-space(string?)
§ 4.2
The false function returns false.
The normalize-space function returns the argument string with
boolean lang(string)
§ 4.3
whitespace normalized by stripping leading and trailing whitespace and
The lang function returns true or false depending on whether the
replacing sequences of whitespace characters by a single space.
language of the context node as specified by xml:lang attributes is the
Quick Reference
boolean starts-with(string, string)
§ 4.2
same as or is a sublanguage of the language specified by the argument
string.
The starts-with function returns true if the first argument string starts
with the second argument string, and otherwise returns false.
boolean not(boolean)
§ 4.3
string string(object?)
§ 4.2
The not function returns true if its argument is false, and false otherwise.
XML Path Language
boolean true()
§ 4.3
The string function converts an object to a string:
NaN is converted to the string NaN,
The true function returns true.
positive zero is converted to the string 0,
(XPath)
NUMBER FUNCTIONS
negative zero is converted to the string 0,
positive infinity is converted to the string Infinity,
Version 1.0
number ceiling(number)
§ 4.4
negative infinity is converted to the string –Infinity,
The ceiling function returns the smallest (closest to negative infinity)
if the number is an integer, the number is represented in decimal
number that is not less than the argument and that is an integer.
form as a Number with no decimal point and no leading zeros,
W3C Recommendation
preceded by a minus sign (-) if the number is negative,
number floor(number)
§ 4.4
16 November 1999
otherwise, the number is represented in decimal form as a Number
The floor function returns the largest (closest to positive infinity) number
including a decimal point with at least one digit before the decimal
that is not greater than the argument and that is an integer.
point and at least one digit after the decimal point, preceded by a
number number(object?)
§ 4.4
minus sign (-) if the number is negative.
The number function converts its argument to a number:
number string-length(string?)
§ 4.2
a string that consists of optional whitespace followed by an optional
The string-length returns the number of characters in the string
minus sign followed by a Number followed by whitespace is converted
string substring(string, number, number?)
§ 4.2
to the IEEE 754 number that is nearest (according to the IEEE 754
Table of Contents:
round-to-nearest rule) to the mathematical value represented by the
The substring function returns the substring of the first argument starting
Location Paths
string; any other string is converted to NaN,
at the position specified in the second argument with length specified in
· Horizontal Axis
boolean true is converted to 1; boolean false is converted to 0,
the third argument.
· Vertical Axis
a node-set is first converted to a string as if by a call to the string
string substring-after(string, string)
§ 4.2
function and then converted in the same way as a string argument,
Core Function Library
The substring-after function returns the substring of the first argument
an object of a type other than the four basic types is converted to a
string that follows the first occurrence of the second argument string in
· Node Set Functions
number in a way that is dependent on that type.
the first argument string, or the empty string if the first argument string
· String Functions
number round(number)
§ 4.4
does not contain the second argument string.
· Boolean Functions
The round function returns the number that is closest to the argument and
· Number Functions
string substring-before(string, string)
§ 4.2
that is an integer.
The substring-before function returns the substring of the first argument
number sum(node-set)
§ 4.4
string that precedes the first occurrence of the second argument string in
The sum function returns the sum, for each node in the argument node-
the first argument string, or the empty string if the first argument string
set, of the result of converting the string-values of the node to a number.
does not contain the second argument string.
string translate(string, string, string)
§ 4.2
The translate function returns the first argument string with occurrences
of characters in the second argument string replaced by the character at
the corresponding position in the third argument string.
BOOLEAN FUNCTIONS
deepX Ltd.
boolean boolean(object)
§ 4.3
Dublin, Ireland
The boolean function converts its argument to a Boolean:
a number is true if and only if it is neither positive or negative zero
nor NaN,
a node-set is true if and only if it is non-empty,
a string is true if and only if its length is non-zero,

ADVERTISEMENT

00 votes

Related Articles

Related forms

Related Categories

Parent category: Education
Go
Page of 2