Appendix D: Using XSLT Functions


Table D-1 describes the transformation methods used to complete an XSL Transformation (XSLT) document.

Table D-1: XSLT Functions

FUNCTION

DESCRIPTION

xsl: apply-imports

Raises the precedence of the current style sheet.

xsl:apply-templates

Invokes the best-match template rules against the node set returned by the select expression.

xsl:attribute

Returns an Extensible Markup Language (XML) attribute whose [local name] is name , whose [namespace URI] is namespace, and whose [children] are based on template.

xsl:call-template

Invokes the template rule named by name.

xsl:choose

Evaluates the template from the first xsl:when clause whose test expression evaluates to true. If none of the test expressions evaluate to true, then the template contained in the xsl: otherwise clause is evaluated.

xsl:comment

Returns an XML comment containing the template as its character data.

xsl:copy

Copies the current context node and associated namespace nodes to the result tree fragment.

xsl:copy-of

Returns the node set corresponding to the select expression.

xsl:element

Returns an XML element whose [local name] is name, whose [namespace URI] is namespace, and whose [children] are based on template.

xsl:fallback

Evaluates the template when the parent instruction/directive is not supported by the current processor.

xsl:for-each

Evaluates the template against each node in node set returned by the select expression. The order of evaluation can be influenced using one or more xsl:sorts.

xsl:if

Evaluates the template if and only if the test expression evaluates to true.

xsl:message

Returns a message in a processor-dependent manner.

xsl:number

Returns a number based on the XPath number expression found in value.

xsl:processing-instruction

Returns an XML processing instruction whose [target] is name and whose [children] are based on template.

xsl:text

Returns the text found in #PCDATA. Escaping of the five built-in entities is controlled using disable-output-escaping .

xsl:value-of

Returns the string corresponding to the select expression.

xsl:variable

Declares a variable name and initializes it using the select expression or template.




Developing. NET Enterprise Applications
Developing .NET Enterprise Applications
ISBN: 1590590465
EAN: 2147483647
Year: 2005
Pages: 119

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net