robert kuzelj | 1 Nov 2005 16:49
Picon

[RFE] add a compare methodto scala.xml.Node

hi burak,

would it be possible to add a compare method to
the Node class that does have some error reporting
facillities?

var x1 = <x><y value="1"/><y value="2"/></x>;
var x2 = <x><y value="2"/><y value="1"/></x>;

var result = x1 compare x2;
Console.println("xpath:" + result.xpath);

>>prints /x/y/ <at> value

you could easily reuse that on the equals method than.

the problem for now is that for large xml trees its
almost impossible to find the difference if x1 != x2.

ciao robertj


Gmane