searchssearchasearchc Wallpaper isearchZsearchna Sexy esearchy Applications r Wallpaper ersearchh Category fn:docfn:doc-availabletrue if a document node can be retrieved
using the specified URI.fn:collectionop:to($firstval as xs:integer,
$lastval as xs:integer) as xs:integer*Summary: Returns the sequence containing every
xs:integer whose value is between the value of
$firstval (inclusive) and the value of
$lastval (inclusive), in monotonic order. If the value
of the first operand is greater than the value of the second, the
empty sequence is returned. If the values of the two operands are
equal, a sequence containing a single xs:integer equal
to the value is returned.
This function backs up the "to" operator.
fn:id($arg as xs:string*) as element()*fn:id($arg as xs:string*, $node as node()) as element()*Summary: Returns the sequence of element nodes that have an
ID value matching the value of one or more of the
IDREF values supplied in $arg .
Note:
This function does not have the desired effect when searching a
document in which elements of type xs:ID are used as
identifiers. To preserve backwards compatibility, a new function
fn:element-with-id
is therefore being introduced; it behaves the same way as
fn:id in the case of ID-valued attributes.
The function returns a sequence, in document order with
duplicates eliminated, containing every element node E
that satisfies all the following conditions:
E is in the target document. The target document is
the document containing $node, or the document
containing the context item (.) if the second argument
is omitted. The behavior of the function if $node is
omitted is exactly the same as if the context item had been passed
as $node. If $node, or the context item
if the second argument is omitted, is a node in a tree whose root
is not a document node [err:FODC0001] is raised. If the second argument
is the context item, or is omitted, the following errors may be
raised: if there is no context item, [err:XPDY0002]XP; if
the context item is not a node [err:XPTY0004]XP.
E has an ID value equal to one of the
candidate IDREF values, where:
An element has an ID value equal to V
if either or both of the following conditions are true:
The is-id property (See Section 5.5 is-id
AccessorDM.) of the element node is
true, and the typed value of the element node is equal to V under
the rules of the eq operator using the Unicode code
point collation
(2005/xpath-functions/collation/codepoint).
The element has an attribute node whose is-id
property (See Section 5.5 is-id
AccessorDM.) is true and whose typed
value is equal to V under the rules of the
eq operator using the Unicode code point collation
(2005/xpath-functions/collation/codepoint).
Each xs:string in $arg is treated as a
whitespace-separated sequence of tokens, each token acting as an
IDREF. These tokens are then included in the list of
candidate IDREF values. If any of the tokens is not a
lexically valid IDREF (that is, if it is not lexically
an xs:NCName), it is ignored. Formally, the candidate
IDREF values are the strings in the sequence given by
the expression:
for $s in $arg return fn:tokenize(fn:normalize-space($s), ' ') [. castable as xs:IDREF]
If several elements have the same ID value, then
E is the one that is first in document order.
Notes:
If the data model is constructed from an Infoset, an attribute
will have the is-id property if the corresponding
attribute in the Infoset had an attribute type of ID:
typically this means the attribute was declared as an
ID in a DTD.
If the data model is constructed from a PSVI, an element or
attribute will have the is-id property if its typed
value is a single atomic value of type xs:ID or a type
derived by restriction from xs:ID.
No error is raised in respect of a candidate IDREF
value that does not match the ID of any element in the
document. If no candidate IDREF value matches the
ID value of any element, the function returns the
empty sequence.
It is not necessary that the supplied argument should have type
xs:IDREF or xs:IDREFS, or that it should
be derived from a node with the is-idrefs
property.
An element may have more than one ID value. This
can occur with synthetic data models or with data models
constructed from a PSVI where the element and one of its attributes
are both typed as xs:ID.
If the source document is well-formed but not valid, it is
possible for two or more elements to have the same ID
value. In this situation, the function will select the first such
element.
It is also possible in a well-formed but invalid document to
have an element or attribute that has the is-id property but whose
value does not conform to the lexical rules for the
xs:ID type. Such a node will never be selected by this
function.
fn:idref($arg as xs:string*) as node()*fn:idref($arg as xs:string*, $node as node()) as node()*Summary: Returns the sequence of element or attribute nodes with
an IDREF value matching the value of one or more of
the ID values supplied in $arg.
The function returns a sequence, in document order with
duplicates eliminated, containing every element or attribute node
$N that satisfies all the following conditions:
$N is in the target document. The target document
is the document containing $node or the document
containing the context item (.) if the second argument
is omitted. The behavior of the function if $node is
omitted is exactly the same as if the context item had been passed
as $node. If $node, or the context item
if the second argument is omitted, is a node in a tree whose root
is not a document node [err:FODC0001] is raised. If the second argument
is the context item, or is omitted, the following errors may be
raised: if there is no context item [err:XPDY0002]XP