From 3f6867910e2f51eac43aa05ae2c3718c026b3818 Mon Sep 17 00:00:00 2001 From: Adam Bem Date: Thu, 30 Mar 2023 10:38:55 +0200 Subject: [PATCH] Added true, false and not boolean functions --- Frontend/tools/xpath.html | 124 +++++++++++++++++++++++++++++++++++--- 1 file changed, 117 insertions(+), 7 deletions(-) diff --git a/Frontend/tools/xpath.html b/Frontend/tools/xpath.html index 12c549f..ceeab09 100644 --- a/Frontend/tools/xpath.html +++ b/Frontend/tools/xpath.html @@ -670,6 +670,81 @@ W3C Documentation reference: Boolean-Functions + + fn:true() +
+ Returns the xs:boolean value true. Equivalent to xs:boolean("1").

+ + Return type: xs:boolean

+ Examples:
+ + + + + + + + + +
ExpressionResult
true()true

+ W3C Documentation reference +
+ + fn:false() +
+ Returns the xs:boolean value false. Equivalent to xs:boolean("0").

+ + Return type: xs:boolean

+ Examples:
+ + + + + + + + + +
ExpressionResult
false()false

+ W3C Documentation reference +
+ + fn:not() +
+ $arg is first reduced to an effective boolean value by applying the fn:boolean() function. Returns true if the effective boolean value is false, and false if the effective boolean value is true.

+ + Arguments and return type: + + + + + + + + + +
TypeDescription
item$arg
+ Return type: xs:boolean

+ Examples:
+ + + + + + + + + + + + + +
ExpressionResult
not(false())true
not(true())false

+ W3C Documentation reference +
@@ -2229,14 +2304,49 @@
- fn:nilled(node) -
+ fn:resolve-uri() +
+ This function enables a relative URI reference to be resolved against an absolute URI. - Returns a Boolean value indicating whether the argument node is nilled
-
- W3C Documentation reference: #func-nilled -
+ The first form of this function resolves $relative against the value of the base-uri property from the static context. If the base-uri property is not initialized in the static context an error is raised [err:FONS0005].
+ + If $relative is a relative URI reference, it is resolved against $base, or against the base-uri property from the static context, using an algorithm such as those described in [RFC 2396] or [RFC 3986], and the resulting absolute URI reference is returned.
+ If $relative is an absolute URI reference, it is returned unchanged.
+ + If $relative is the empty sequence, the empty sequence is returned.
+ + If $relative is not a valid URI according to the rules of the xs:anyURI data type, or if it is not a suitable relative reference to use as input to the chosen resolution algorithm, then an error is raised [err:FORG0002].
+ + If $base is not a valid URI according to the rules of the xs:anyURI data type, if it is not a suitable URI to use as input to the chosen resolution algorithm (for example, if it is a relative URI reference, if it is a non-hierarchic URI, or if it contains a fragment identifier), then an error is raised [err:FORG0002].
+ + If the chosen resolution algorithm fails for any other reason then an error is raised [err:FORG0009].
+ +

Note:

+ + Resolving a URI does not dereference it. This is merely a syntactic operation on two character strings. +

+ + + Arguments and return type: + + + + + + + + + + + + + +
TypeDescription
xs:string?$relative
xs:string$base
+ Return type: xs:anyURI?

+
+ W3C Documentation reference +