Added an explicit copy for the namespace nodes of the elements
treated equal.
Version 1.5 / 2002-01-29
Added the stylesheet parameter "replace" (default value: false).
If set to true by assigning any other value, text nodes from the
first document will be replaced by corresponding nodes from the
second document. However, text nodes within a singular element
will be copied as part of the element. The algorithm affects only
text nodes for which in non-replace mode an equivalent node has to
be found.
Version 1.4 / 2001-12-05
Added the stylesheet parameter "dontmerge". Assigning a string
(denoting a qualified element name) will force the stylesheet
to treat all elements with this name to be different. Thus
elements with this name won't be merged.
Version 1.3 / 2000-08-13
Improved performance. If there is an equivalent node in the
other node set, all preceding nodes will be copied at once.
Version 1.2 took only the first node of that node set and made
an recursive template call, thus testing again for an equivalent
node.
Version 1.2 / 2000-08-06
Merging is now more flexible. Two equivalent nodes may be
matched, even if they don't appear exactly at the same position
within their node sets.
The algorithm for merging two node sets is now: Compare the
first nodes.
If they are equivalent, create one result node by merging the
children, and merge the rest of the two node sets. (Unchanged)
If they are not equivalent, check if there is an equivalent
node for the first node of the first node set within the other
nodes of the second node set. If no: copy this first node to
the result tree and merge the rest with the second node set. If
yes: copy the first node of the second node set to the result
tree and merge the rest with the whole first node set.
(Internally) Changed template names and mode names to be within
the namespace "http://informatik.hu-berlin.de/merge".
Version 1.1 / 2000-07-26
Changed the second parameter passed to the document function
from "/" to "/*" because of
problems with Xalan 1.0.1 and Saxon 5.4.
Changed the code for comparing node types.
Fixed bug in comparing attributes: the test expression is now
"string-length($diff)". The former test
"$diff" should return always true
(according to the specification).
This transformation sheet now works also with XT!