On Fri, 15 Feb 2002 00:50, Berin Loritsch wrote: > Peter Donald wrote: > > Hi, > > > > Im still not sure I am comfortable with doing the mergin this way rather > > than through utlity methods. The main reason is there are different > > strategies to use when merging consider the following > > > > Source: <a/> > > Default: <a><b/></a> > > > > The result will most likely be equal to the "Default" tree. But what > > happens in the following cases > > > > Source: <a><b/></a> > > Default: <a><b/></a> > > > > Do we double the B or replace it? > > > > Source: <a><b x="1"/></a> > > Default: <a><b/></a> > > > > Do we double the B or replace it? > > > > Source: <a><b x="1"/></a> > > Default: <a><b y="2"/></a> > > > > Do we double the B or replace it or merge it? > > > > Source: <a><b x="1"/></a> > > Default: <a><b x="2" y="2"/></a> > > > > Do we double the B or replace it or merge it? > > In all of those situations, I believe the desire was for the Source to > override the default. So in each of your examples (numbered 1-5) the > results are listed: > > 1. <a><b/></a> > 2. <a><b/></a> > 3. <a><b x="1"/></a> > 4. <a><b x="1" y="2"/></a> > 5. <a><b x="1" y="2"/></a> > > So the Default provides base values, and the Source will override those > values when provided.
Thats how I would expect it to behave but thats not how Stephen expects it to behave :) And I didn't even comment on the potential more painful example Source: <a><b x="1"/></a> Default: <a><b/><a/><b x="2" y="2"/></a> Result == ? -- Cheers, Pete -------------------------------------------------------------- "Science is like sex: sometimes something useful comes out, but that is not the reason we are doing it" -- Richard Feynman -------------------------------------------------------------- -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
