xsl-list
[Top] [All Lists]

How to verify equivalence of two node trees ?

2004-10-27 22:36:23
Assume we have two node trees with the root nodes $aroot and $broot:

<xsl:variable name="aroot" select="...." />
<xsl:variable name="broot" select="...." />

How can I test the equivalence of the two node trees ?
More precisely there are should be three kinds of tests:

1.) Testing if tree a is equal to tree b only looking at the elements
but ignoring possible existing attributes and their values

2.) Testing if tree a is equal to tree b regarding the elements and their
attributes but ignoring the values of the attributes

3.) Finally testing if tree a is equal to tree b regarding elements,
their attribute (names) and the attribbute values.

How can I implement such a test in XSLT?
Is there possibly a smarter solution in XSLT 2.0 ?

Matt
-- 
___________________________________________________________
Sign-up for Ads Free at Mail.com
http://promo.mail.com/adsfreejump.htm



<Prev in Thread] Current Thread [Next in Thread>