Index: Ringtoets/Piping/src/Ringtoets.Piping.Data/PipingInput.cs
===================================================================
diff -u -r10779bb6a6db2d00f4627b2bc190e7e35e1fee3e -r1e49eb86c81e8446aeb6031cfd7a209bb0c11bac
--- Ringtoets/Piping/src/Ringtoets.Piping.Data/PipingInput.cs (.../PipingInput.cs) (revision 10779bb6a6db2d00f4627b2bc190e7e35e1fee3e)
+++ Ringtoets/Piping/src/Ringtoets.Piping.Data/PipingInput.cs (.../PipingInput.cs) (revision 1e49eb86c81e8446aeb6031cfd7a209bb0c11bac)
@@ -38,11 +38,6 @@
public class PipingInput : Observable
{
private readonly GeneralPipingInput generalInputParameters;
- private RoundedDouble assessmentLevel;
- private RoundedDouble exitPointL;
- private RoundedDouble entryPointL;
- private RoundedDouble piezometricHeadExit;
- private RingtoetsPipingSurfaceLine surfaceLine;
private readonly NormalDistribution phreaticLevelExit;
private readonly LognormalDistribution dampingFactorExit;
private readonly LognormalDistribution thicknessCoverageLayer;
@@ -51,7 +46,16 @@
private readonly LognormalDistribution darcyPermeability;
private readonly LognormalDistribution diameter70;
private readonly LognormalDistribution seepageLength;
+ private RoundedDouble assessmentLevel;
+ private RoundedDouble exitPointL;
+ private RoundedDouble entryPointL;
+ private RoundedDouble piezometricHeadExit;
+ private RingtoetsPipingSurfaceLine surfaceLine;
+ private readonly PipingInputSynchronizer synchronizer;
+ private PipingSoilProfile soilProfile;
+ private HydraulicBoundaryLocation hydraulicBoundaryLocation;
+
///
/// Initializes a new instance of the class.
///
@@ -76,67 +80,37 @@
phreaticLevelExit = new NormalDistribution(3);
dampingFactorExit = new LognormalDistribution(3)
{
- Mean = (RoundedDouble)0.7,
- StandardDeviation = (RoundedDouble)0.0
+ Mean = (RoundedDouble) 0.7,
+ StandardDeviation = (RoundedDouble) 0.0
};
thicknessCoverageLayer = new LognormalDistribution(2)
{
- Mean = (RoundedDouble)double.NaN,
- StandardDeviation = (RoundedDouble)0.5
+ Mean = (RoundedDouble) double.NaN,
+ StandardDeviation = (RoundedDouble) 0.5
};
saturatedVolumicWeightOfCoverageLayer = new ShiftedLognormalDistribution(2)
{
Shift = (RoundedDouble) 10,
Mean = (RoundedDouble) 17.5,
- StandardDeviation = (RoundedDouble)0
+ StandardDeviation = (RoundedDouble) 0
};
seepageLength = new LognormalDistribution(2)
{
- Mean = (RoundedDouble)double.NaN,
- StandardDeviation = (RoundedDouble)double.NaN
+ Mean = (RoundedDouble) double.NaN,
+ StandardDeviation = (RoundedDouble) double.NaN
};
diameter70 = new LognormalDistribution(2);
darcyPermeability = new LognormalDistribution(3);
thicknessAquiferLayer = new LognormalDistribution(2)
{
- Mean = (RoundedDouble)double.NaN,
- StandardDeviation = (RoundedDouble)0.5
+ Mean = (RoundedDouble) double.NaN,
+ StandardDeviation = (RoundedDouble) 0.5
};
- }
- ///
- /// Gets or sets the outside high water level.
- /// [m]
- ///
- public RoundedDouble AssessmentLevel
- {
- get
- {
- return assessmentLevel;
- }
- set
- {
- assessmentLevel = value.ToPrecision(assessmentLevel.NumberOfDecimalPlaces);
- }
+ synchronizer = new PipingInputSynchronizer(this);
}
///
- /// Gets or sets the piezometric head at the exit point.
- /// [m]
- ///
- public RoundedDouble PiezometricHeadExit
- {
- get
- {
- return piezometricHeadExit;
- }
- set
- {
- piezometricHeadExit = value.ToPrecision(piezometricHeadExit.NumberOfDecimalPlaces);
- }
- }
-
- ///
/// Gets or sets the l-coordinate of the entry point, which, together with
/// the l-coordinate of the exit point, is used to determine the seepage
/// length of .
@@ -156,6 +130,7 @@
throw new ArgumentOutOfRangeException("value", Resources.PipingInput_EntryPointL_Value_must_be_greater_than_or_equal_to_zero);
}
entryPointL = value.ToPrecision(entryPointL.NumberOfDecimalPlaces);
+ synchronizer.Synchronize();
}
}
@@ -179,6 +154,7 @@
throw new ArgumentOutOfRangeException("value", Resources.PipingInput_ExitPointL_Value_must_be_greater_than_zero);
}
exitPointL = value.ToPrecision(exitPointL.NumberOfDecimalPlaces);
+ synchronizer.Synchronize();
}
}
@@ -195,19 +171,78 @@
{
surfaceLine = value;
UpdateEntryAndExitPoint();
+ synchronizer.Synchronize();
}
}
///
/// Gets or sets the profile which contains a 1 dimensional definition of soil layers with properties.
///
- public PipingSoilProfile SoilProfile { get; set; }
+ public PipingSoilProfile SoilProfile
+ {
+ get
+ {
+ return soilProfile;
+ }
+ set
+ {
+ soilProfile = value;
+ synchronizer.Synchronize();
+ }
+ }
///
/// Gets or set the hydraulic boundary location from which to use the assessment level.
///
- public HydraulicBoundaryLocation HydraulicBoundaryLocation { get; set; }
+ public HydraulicBoundaryLocation HydraulicBoundaryLocation
+ {
+ get
+ {
+ return hydraulicBoundaryLocation;
+ }
+ set
+ {
+ hydraulicBoundaryLocation = value;
+ synchronizer.Synchronize();
+ }
+ }
+ #region Derived input
+
+ ///
+ /// Gets or sets the outside high water level.
+ /// [m]
+ ///
+ public RoundedDouble AssessmentLevel
+ {
+ get
+ {
+ return assessmentLevel;
+ }
+ set
+ {
+ assessmentLevel = value.ToPrecision(assessmentLevel.NumberOfDecimalPlaces);
+ }
+ }
+
+ ///
+ /// Gets or sets the piezometric head at the exit point.
+ /// [m]
+ ///
+ public RoundedDouble PiezometricHeadExit
+ {
+ get
+ {
+ return piezometricHeadExit;
+ }
+ set
+ {
+ piezometricHeadExit = value.ToPrecision(piezometricHeadExit.NumberOfDecimalPlaces);
+ }
+ }
+
+ #endregion
+
#region General input parameters
///
@@ -355,6 +390,7 @@
{
phreaticLevelExit.Mean = value.Mean;
phreaticLevelExit.StandardDeviation = value.StandardDeviation;
+ synchronizer.Synchronize();
}
}