5 Matching Annotations
- May 2020
-
nwalsh.com nwalsh.com
-
Regular Expression Functions There are three regular-expression functions that operate on strings: matches() tests if a regular expression matches a string. replace() uses regular expressions to replace portions of a string. tokenize() returns a sequence of strings formed by breaking a supplied input string at any separator that matches a given regular expression. Example:
Test question: how many are there regular-expression functions in XSLT?
-
position()
The position function returns a number equal to the context position from the expression evaluation context.
-
What’s the difference between xsl:value-of, xsl:copy-of, and xsl:sequence? xsl:value-of always creates a text node. xsl:copy-of always creates a copy. xsl:sequence returns the nodes selected, subject possibly to atomization. Sequences can be extended with xsl:sequence.
What’s the difference between xsl:value-of, xsl:copy-of, and xsl:sequence?
-
<xsl:variable name="date" select="xs:date('2003-11-20')"/>
How to declare the date in the variable in XSLT 2?
-
Types XSLT 2.0 allows you to declare: The type of variables. The return type of templates. The type of sequences (constructed with xsl:sequence) The return type of (user-declared) functions. Both the type and required type of parameters.
What are the types that one can declare in XSLT 2?
-