<xsl:key
name = QName
match = Pattern
use = Expression
</xsl:key>
name
Specifies the Qualified Names of the key.
match
Specifies the Patterns that identifies a node that holds this key.
use
Specifies an Expressions to be used as the value of the key. The key value can be one of the following: an attribute, a child element, or the content of the matched element.
key() prototype:
node-set key(name, value)
name is in string format
xsl:key works together with key() function. Key is useful when there are large amount of look ups.
key works like ids. You define it at the top level of the document. Then you can use key() function to select the elements at the fly.