public override void Compare(IComparison <IEventAssignment> comparison)
 {
     _entityDiffBuilder.Compare(comparison);
     CompareValues(x => x.UseAsValue, x => x.UseAsValue, comparison);
     _objectComparer.Compare(comparison.FormulaComparison());
     // Not Nessessary to compare Changed Object.
 }
Esempio n. 2
0
 public override void Compare(IComparison <IEventAssignmentBuilder> comparison)
 {
     _entityDiffBuilder.Compare(comparison);
     CompareValues(x => x.UseAsValue, x => x.UseAsValue, comparison);
     CompareValues(x => x.Dimension, x => x.Dimension, comparison);
     _objectComparer.Compare(comparison.FormulaComparison());
 }
Esempio n. 3
0
 public override void Compare(IComparison <ITransport> comparison)
 {
     _containerDiffBuilder.Compare(comparison);
     CompareValues(x => _entityPathResolver.PathFor(x.TargetAmount), Captions.Diff.TargetAmount, comparison);
     CompareValues(x => _entityPathResolver.PathFor(x.SourceAmount), Captions.Diff.SourceAmount, comparison);
     _objectComparer.Compare(comparison.FormulaComparison());
 }
Esempio n. 4
0
 public override void Compare(IComparison <IObserverBuilder> comparison)
 {
     _entityDiffBuilder.Compare(comparison);
     _moleculeDependentDiffBuilder.Compare(comparison);
     CompareValues(x => x.ContainerCriteria, x => x.ContainerCriteria, comparison);
     CompareValues(x => x.Dimension, x => x.Dimension, comparison);
     _objectComparer.Compare(comparison.FormulaComparison());
 }
Esempio n. 5
0
 public override void Compare(IComparison <IEvent> comparison)
 {
     _entityDiffBuilder.Compare(comparison);
     CompareValues(x => x.OneTime, x => x.OneTime, comparison);
     _objectComparer.Compare(comparison.FormulaComparison());
     _enumerableComparer.CompareEnumerables(comparison, x => x.Assignments, item => _entityPathResolver.ObjectPathFor(item.ChangedEntity));
     _enumerableComparer.CompareEnumerables(comparison, x => x.GetChildren <IEntity>(i => !i.IsAnImplementationOf <IEventAssignment>()), item => item.Name);
 }
 public override void Compare(IComparison <IReaction> comparison)
 {
     _containerDiffBuilder.Compare(comparison);
     _objectComparer.Compare(comparison.FormulaComparison());
     _enumerableComparer.CompareEnumerables(comparison, x => x.Educts, item => item.Partner.Name);
     _enumerableComparer.CompareEnumerables(comparison, x => x.Products, item => item.Partner.Name);
     _enumerableComparer.CompareEnumerables(comparison, x => x.ModifierNames, item => item, missingItemType: ObjectTypes.Modifier);
 }
Esempio n. 7
0
 public override void Compare(IComparison <ITransportBuilder> comparison)
 {
     _containerDiffBuilder.Compare(comparison);
     CompareValues(x => x.SourceCriteria, x => x.SourceCriteria, comparison);
     CompareValues(x => x.TargetCriteria, x => x.TargetCriteria, comparison);
     CompareValues(x => x.Dimension, x => x.Dimension, comparison);
     _moleculeDependentBuilderDiffBuilder.Compare(comparison);
     _objectComparer.Compare(comparison.FormulaComparison());
 }
 public override void Compare(IComparison <IReactionBuilder> comparison)
 {
     _containerDiffBuilder.Compare(comparison);
     _objectComparer.Compare(comparison.FormulaComparison());
     _enumerableComparer.CompareEnumerables(comparison, x => x.Educts, item => item.MoleculeName);
     _enumerableComparer.CompareEnumerables(comparison, x => x.Products, item => item.MoleculeName);
     _enumerableComparer.CompareEnumerables(comparison, x => x.ModifierNames, item => item, missingItemType: ObjectTypes.Modifier);
     CompareValues(x => x.ContainerCriteria, x => x.ContainerCriteria, comparison);
     CompareValues(x => x.Dimension, x => x.Dimension, comparison);
 }
        protected virtual void CompareStartValue(IComparison <T> comparison)
        {
            _entityDiffBuilder.Compare(comparison);
            CompareValues(x => x.Dimension, x => x.Dimension, comparison);
            CompareValues(x => x.ContainerPath, x => x.ContainerPath, comparison);

            // Always Compare Value and Formula, independent from settings as these are two different properties of a start value
            CompareNullableDoubleValues(x => x.StartValue, x => x.StartValue, comparison, x => x.DisplayUnit);
            _objectComparer.Compare(comparison.FormulaComparison());
        }
Esempio n. 10
0
        private void compareQuantities(IComparison <IQuantity> comparison)
        {
            _entityDiffBuilder.Compare(comparison);
            CompareValues(x => x.Dimension, x => x.Dimension, comparison);
            CompareValues(x => x.QuantityType, x => x.QuantityType, comparison);
            CompareValues(x => x.NegativeValuesAllowed, x => x.NegativeValuesAllowed, comparison);

            if (!comparison.Settings.OnlyComputingRelevant)
            {
                CompareValues(x => x.Persistable, x => x.Persistable, comparison);
                CompareValues(x => x.DisplayUnit, Captions.DisplayUnit, comparison);
            }

            if (shouldCompareValues(comparison))
            {
                CompareDoubleValues(x => x.Value, x => x.Value, comparison, x => x.DisplayUnit);
            }
            else
            {
                _objectComparer.Compare(comparison.FormulaComparison());
            }
        }
Esempio n. 11
0
 public override void Compare(IComparison <IApplicationMoleculeBuilder> comparison)
 {
     _entityDiffBuilder.Compare(comparison);
     CompareValues(x => x.RelativeContainerPath, x => x.RelativeContainerPath, comparison, Equals, (molecule, path) => path.PathAsString);
     _objectComparer.Compare(comparison.FormulaComparison());
 }