XPath expressions

Previous Next

 

 

In XPath contexts, the USoft Blend framework processes XPath expressions.

XPath is embedded in XSLT 1.0 and in USoft Blend. It is a general expression language with node set expressions as its specialising characteristic. Node set expressions are evaluated relative to a location in an XML document being traversed. They allow you to point from that context to nodes in the XML document in a set-oriented fashion.

All the XPath 1.0 types of expression and their data types apply:

Type of XPath expression

Returns data type

Explanation

Examples

xpath-expression 
(for short: xpath)

Any

Any XPath expression.

 

All the items in this table subset xpath-expression.

 

node set-expression

Node set

An XPath expression representing a node set.

node()

pc:*

/parent/child[1]

 

absolute-location-path

Node set

A node set expression that DOES start with the / character

/parent/child[1]

relative-location-path

Node set

A node set expression that does NOT start with the / character

node()

pc:*

boolean

Boolean

A value expressing the concept of either "true" or "false".

$is-valid

 

true()

string

String

A sequence of Unicode characters.

'ABC110'

"My variable value"

number

Number

A floating-point number.

98

 

24.7

function-call

Any

A parenthesised expression that calls either

a USoft Blend function or an XPath function.

dates:ShowInputFormats()

concat('A', 'B')

variable-reference

Any

A placeholder representing a variable.

$myvar

 

 

See also

Guide to expressions and data types

          Literal expressions

                  Dates

                  string literals

          Path expressions

          XML expressions

          XPath expressions

                 Node set expressions

                 Booleans

                 Strings

                 Numbers

                 Function calls

                 Variable references

                 Implicit XPath datatype conversion

                 Evaluated expressions vs. literals

          SQL expressions