Chapter 11. XSLT Functions and Related XSLT Elements

  • current(), document(), element-available(), format-number(), function-available(), generate-id(), key(), system-property(), unparsed-entity-uri()

  • <xsl:key>

  • <xsl:decimal-format>

The versatility of XSLT is greatly enhanced by the range of XPath functions (described in Chapter 5), which provide the ability to perform many sophisticated tasks. XSLT provides its own library of functions, specific to XSLT implementations, in addition to the core XPath library of functions. These XSLT functions are used within expressions and are declared by the XSLT specification in the same manner as XPath functions, using a function prototype, as shown in the following structure:

Function: return type
						name(arguments)
					

This chapter will discuss the nine XSLT functions, which are summarized in Table 11-1, as well as the two XSLT elements <xsl:key> and <xsl:decimal-format> and their relationships to the key() and format-number() functions, respectively. The reference number in the last column provides a quick lookup for the section of this chapter specifically applicable to a given function.

Table 11-1. XSLT functions
Function Name XSLT Function Group Returns Arguments Argument Type Ref.
current() Node-set Node-set None None 11.1.2
document() Node-set Node-set Object Node-set Required Optional 11.1.1.1
element-available() Boolean Boolean String Required 11.3.1
format-number() String String Number String String Required Required Optional 11.2.3
function-available() Boolean Boolean String Required 11.3.2
generate-id() String String Node-set Optional 11.2.2
key() Node-set Node-set String Object Required Required 11.1.3
system-property() String Object String Required 11.2.1
unparsed-entity-uri() String String String Required 11.2.4

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.188.218.184