public override bool CompareTo(object Comparand) { FWOpenableDocument cmpDoc = Comparand as FWOpenableDocument; bool docEmpty = cmpDoc == null ? true : cmpDoc.IsEmpty(); bool CurrentIsEmpty = this.IsEmpty(); if (cmpDoc != null) { if (docEmpty) { return(CurrentIsEmpty); } else if (!CurrentIsEmpty) { return(InternalCompare(cmpDoc)); } else { return(true); } } else { return(CurrentIsEmpty); } }
public override Comparison.IDiffViewer GetDifferenceViewer(object Comparand) { FWOpenableDocument cmpDoc = Comparand as FWOpenableDocument; var DiffViewer = new Comparison.FWDiffViewer(this, cmpDoc); return(DiffViewer); }
protected override bool InternalCompare(FWOpenableDocument cmpDoc) { if (cmpDoc is DCSSchemaDocument) { return(SchemaContent == ((DCSSchemaDocument)cmpDoc).SchemaContent); } else { return(false); } }
protected virtual bool InternalCompare(FWOpenableDocument cmpDoc) { Comparison.StreamComparator sc = new Comparison.StreamComparator(); return(sc.CompareStreams(GetDataStream(), cmpDoc.GetDataStream())); }