Proposal: has-name-match()

"\"John L. Clark\"" <[email protected]> Mon, 22 Jan 2007 10:10:23 -0500
Newsgroups gmane.text.xml.xslt.extensions
Message-ID <[email protected]>
I propose a new EXSLT function that might be called
`has-name-match()`.  The signature for this function would be similar
to the following:

  boolean has-name-match(node-set a, node-set b, integer distance?)

This function would examine the first node of both a and b and
determine if the name of each element on the ancestor-or-self axis for
each of these nodes is the same, up to distance from each node.  More
precisely, `has-name-match()` returns true if and only if
(local-name(a) = local-name(b) and namespace-uri(a) = namespace-uri(b)
and has-name-match(a/.., b/.., distance - 1)).

Thoughts?

Take care,

    John L. Clark