public SimulationSettingsDiffBuilder(ObjectBaseDiffBuilder objectBaseDiffBuilder, EnumerableComparer enumerableComparer, IObjectComparer objectComparer) { _objectBaseDiffBuilder = objectBaseDiffBuilder; _enumerableComparer = enumerableComparer; _objectComparer = objectComparer; }
/// <summary> /// Construct a fresh instance /// </summary> /// <param name="objectFlattener">The underlying object flattener to use to convert objects to a comparable state</param> /// <param name="underlyingComparer">The underlying object comparer to use to compare the objects</param> public ObjectSetComparer( BorsukSoftware.ObjectFlattener.IObjectFlattener objectFlattener, IObjectComparer underlyingComparer) { this.ObjectFlattener = objectFlattener; this.UnderlyingComparer = underlyingComparer; }
public DataTableLoaderView(DataTableLoader dataTableLoader, IObjectComparer defaultObjectComparer, ObjectToFilterableConverter defaultObjectToFilterableConverter) { if (dataTableLoader == null) { throw new ArgumentNullException("dataTableLoader"); } if (dataTableLoader.Table == null) { throw new ArgumentException("dataTableLoader.Table is null"); } if (defaultObjectComparer == null) { throw new ArgumentNullException("defaultObjectComparer"); } if (defaultObjectToFilterableConverter == null) { throw new ArgumentNullException("defaultObjectToFilterableConverter"); } this.DataTableLoader = dataTableLoader; this.DefaultObjectComparer = defaultObjectComparer; this.DefaultObjectToFilterableConverter = defaultObjectToFilterableConverter; this.FilterSupportDescriptions.ListChanging += this.FilterSupportDescriptions_ListChanging; this.FilterSupportDescriptions.ListChanged += this.FilterSupportDescriptions_ListChanged; this.SortSupportDescriptions.ListChanging += this.SortSupportDescriptions_ListChanging; this.SortSupportDescriptions.ListChanged += this.SortSupportDescriptions_ListChanged; }
public EventDiffBuilder(EntityDiffBuilder entityDiffBuilder, EnumerableComparer enumerableComparer, IObjectComparer objectComparer, IEntityPathResolver entityPathResolver) { _entityDiffBuilder = entityDiffBuilder; _enumerableComparer = enumerableComparer; _objectComparer = objectComparer; _entityPathResolver = entityPathResolver; }
public ComparisonPresenter(IComparisonView view, IObjectComparer objectComparer, IDiffItemToDiffItemDTOMapper diffItemDTOMapper, IDiffItemDTOsToDataTableMapper dataTableMapper) : base(view) { _objectComparer = objectComparer; _diffItemDTOMapper = diffItemDTOMapper; _dataTableMapper = dataTableMapper; _view.DifferenceTableVisible = false; }
public IndividualDiffBuilder( ContainerDiffBuilder containerDiffBuilder, IObjectComparer comparer, EnumerableComparer enumerableComparer) { _containerDiffBuilder = containerDiffBuilder; _comparer = comparer; _enumerableComparer = enumerableComparer; }
public UserComparer(IObjectComparer primitiveComparer, IEnumerationComparer enumerationComparer) { ValidationGuard.CheckNull(primitiveComparer, nameof(primitiveComparer)); ValidationGuard.CheckNull(enumerationComparer, nameof(enumerationComparer)); _primitiveComparer = primitiveComparer; _enumerationComparer = enumerationComparer; }
public void SetUp() { _comparer = new ObjectComparer().Ignore <IMessage, Guid>(x => x.MessageId) .Ignore <IEvent, Guid>(x => x.CausationId) .Ignore <IEvent, Guid>(x => x.CorrelationId) .Ignore <IMessage, DateTimeOffset>(x => x.Timestamp) .Ignore <IMessage, DateTimeOffset>(x => x.CorrelationTimestamp); ObjectComparisonResult.ThrowOnFail = true; }
protected override void Context() { _view = A.Fake <IComparisonView>(); _diffItemDTOMapper = A.Fake <IDiffItemToDiffItemDTOMapper>(); _objectComparer = A.Fake <IObjectComparer>(); _dataTableMapper = A.Fake <IDiffItemDTOsToDataTableMapper>(); sut = new ComparisonPresenter(_view, _objectComparer, _diffItemDTOMapper, _dataTableMapper); _settings = new ComparerSettings(); _object1 = A.Fake <IObjectBase>(); _object2 = A.Fake <IObjectBase>(); _report = new DiffReport(); A.CallTo(() => _objectComparer.Compare(_object1, _object2, _settings)).Returns(_report); }
public int ComparePrimitive(object x, object y) { x = ReType(x); y = ReType(y); if (x.GetType() == y.GetType()) { return((x as IComparable).CompareTo(y)); } IObjectComparer cmp = comparers[x.GetType() + ":" + y.GetType()] as IObjectComparer; if (cmp != null) { return(cmp.Compare(x, y)); } throw new ArgumentException("Unable to compare " + x.GetType() + " and " + y.GetType()); }
public int ComparePrimitive(object x, object y) { x = ReType(x); y = ReType(y); if (x.GetType() == y.GetType()) { return((x as IComparable).CompareTo(y)); } IObjectComparer cmp = comparers[string.Format("{0}:{1}", x.GetType(), y.GetType())] as IObjectComparer; if (cmp != null) { return(cmp.Compare(x, y)); } throw new ArgumentException(string.Format("Unable to compare {0} and {1}", x.GetType(), y.GetType())); }
public ChartTemplateDiffBuilder(EnumerableComparer enumerableComparer, IObjectComparer objectComparer) { _enumerableComparer = enumerableComparer; _objectComparer = objectComparer; }
public CurveTemplateDiffBuilder(IObjectComparer objectComparer) { _objectComparer = objectComparer; }
public MoleculeBuilderDiffBuilder(ContainerDiffBuilder containerDiffBuilder, IObjectComparer objectComparer, EnumerableComparer enumerableComparer) { _containerDiffBuilder = containerDiffBuilder; _objectComparer = objectComparer; _enumerableComparerComparer = enumerableComparer; }
public IndividualDiffBuilder(ContainerDiffBuilder containerDiffBuilder, IObjectComparer comparer) { _containerDiffBuilder = containerDiffBuilder; _comparer = comparer; }
public EventAssignmentDiffBuilder(EntityDiffBuilder entityDiffBuilder, IObjectComparer objectComparer) { _entityDiffBuilder = entityDiffBuilder; _objectComparer = objectComparer; }
public ResponseAssertions Body(IObjectComparer comparer) { AddTask(VerifyBody(comparer.Validate)); return(this); }
public ExpressionProfileDiffBuilder(IObjectComparer comparer) { _comparer = comparer; }
public SimulationDiffBuilder(ILazyLoadTask lazyLoadTask, IObjectComparer comparer) { _lazyLoadTask = lazyLoadTask; _comparer = comparer; }
protected StartValueDiffBuilder(IObjectComparer objectComparer, EntityDiffBuilder entityDiffBuilder, WithValueOriginComparison <T> valueOriginComparison) { _objectComparer = objectComparer; _entityDiffBuilder = entityDiffBuilder; _valueOriginComparison = valueOriginComparison; }
public void TearDown() { comparer = null; }
public void SetUp() { comparer = new ObjectComparer(); }
public MoBiBuildConfigurationDiffBuilder(IObjectComparer objectComparer) { _objectComparer = objectComparer; }
public MoleculeStartValueDiffBuilder(IObjectComparer objectComparer, EntityDiffBuilder entityDiffBuilder, WithValueOriginComparison <IMoleculeStartValue> valueOriginComparison) : base(objectComparer, entityDiffBuilder, valueOriginComparison) { }
public void Sort(IObjectComparer objectComparer) { throw new NotImplementedException(); }
public MoBiSimulationDiffBuilder(IObjectComparer objectComparer) { _objectComparer = objectComparer; }
public ReactionBuilderDiffBuilder(IObjectComparer objectComparer, ContainerDiffBuilder containerDiffBuilder, EnumerableComparer enumerableComparer) { _containerDiffBuilder = containerDiffBuilder; _enumerableComparer = enumerableComparer; _objectComparer = objectComparer; }
public ParameterStartValueDiffBuilder(IObjectComparer objectComparer, EntityDiffBuilder entityDiffBuilder, WithValueOriginComparison <IParameterStartValue> valueOriginComparison) : base(objectComparer, entityDiffBuilder, valueOriginComparison) { }
public void TearDown() { comparer = null; }
public ParameterDiffBuilder(QuantityDiffBuilder quantityDiffBuilder, IObjectComparer objectComparer) { _quantityDiffBuilder = quantityDiffBuilder; _objectComparer = objectComparer; }
public ObserverBuilderDiffBuilder(EntityDiffBuilder entityDiffBuilder, MoleculeDependentBuilderDiffBuilder moleculeDependentDiffBuilder, IObjectComparer objectComparer) { _entityDiffBuilder = entityDiffBuilder; _moleculeDependentDiffBuilder = moleculeDependentDiffBuilder; _objectComparer = objectComparer; }
public void SetUp() { comparer = new ObjectComparer(); }