From: SourceForge.net <no...@so...> - 2010-01-07 16:23:12
|
Feature Requests item #2927652, was opened at 2010-01-07 17:23 Message generated for change (Tracker Item Submitted) made by bblankenburg You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=377771&aid=2927652&group_id=23187 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Bastian Blankenburg (bblankenburg) Assigned to: Nobody/Anonymous (nobody) Summary: XML ID dereferencing difference engine Initial Comment: We have several cases where the XML ID / IDREF is used to save space for re-used elements. In such cases, the XML IDs are generated local to the XML document and do not have to be equal across documents even though their content is equivalent. For such cases, I subclasses the difference engine to not compare values of attributes with type IDREF directly, but compare the referenced elements instead. However, to determine the schema type of an attribute, it is necessary to obtain the Document via a validating parser. Thus, my implementation takes the schema and control XML source on construction, which is not elegant and makes the engine applicable only for XMLs of the given schema. Probably this feature could be better implemented in XMLUnit. Also, I added a wrapper for ComparisonController, because the standard Diff takes a DifferenceEngine on construction which cannot be changed afterwards and vice versa. So there does not seem to be a good way to use a subclass of DifferenceEngine with a standard Diff instance, but maybe I overlooked sth. here. Sources are attached. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=377771&aid=2927652&group_id=23187 |