public override void Merge(INode Remote, MergeBehaviors Behavior) { if (Identifier == Remote.Identifier) { ITreeNode RemoteTree = (ITreeNode)Remote, SatelliteTree = (ITreeNode)Satellites.Single((n) => (n.Identifier == Remote.Identifier)); foreach (INode Child in Children) { // Shitty override logic. } } base.Merge(Remote, Behavior); }
public virtual void Merge(INode Remote, MergeBehaviors Behavior) { if (Identifier == Remote.Identifier) { INodeLocal Previous; if (Satellites.All((n) => (n.Identifier != Remote.Identifier))) { Previous = Remote; // TODO: Add unseen remote node to satellites. } else { Previous = Satellites.Single( (Satellite) => (Satellite.Identifier == Remote.Identifier)); } // TODO: Shitty behavior logic. OnMergeUpdate(this, EventArgs.Empty); } }