Index: Riskeer/GrassCoverErosionInwards/src/Riskeer.GrassCoverErosionInwards.Forms/Properties/Resources.Designer.cs
===================================================================
diff -u -rbf06bd5c42db48d0551ab19a5c957f732a913b3a -r950c2bc06cda222b149f4663db732cf1c4554dbe
--- Riskeer/GrassCoverErosionInwards/src/Riskeer.GrassCoverErosionInwards.Forms/Properties/Resources.Designer.cs (.../Resources.Designer.cs) (revision bf06bd5c42db48d0551ab19a5c957f732a913b3a)
+++ Riskeer/GrassCoverErosionInwards/src/Riskeer.GrassCoverErosionInwards.Forms/Properties/Resources.Designer.cs (.../Resources.Designer.cs) (revision 950c2bc06cda222b149f4663db732cf1c4554dbe)
@@ -1,4 +1,25 @@
-//------------------------------------------------------------------------------
+// Copyright (C) Stichting Deltares 2019. All rights reserved.
+//
+// This file is part of Riskeer.
+//
+// Riskeer is free software: you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation, either version 3 of the License, or
+// (at your option) any later version.
+//
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this program. If not, see .
+//
+// All names, logos, and references to "Deltares" are registered trademarks of
+// Stichting Deltares and remain full property of Stichting Deltares at all times.
+// All rights reserved.
+
+//------------------------------------------------------------------------------
//
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
Index: Riskeer/GrassCoverErosionInwards/src/Riskeer.GrassCoverErosionInwards.Forms/Views/GrassCoverErosionInwardsCalculationRow.cs
===================================================================
diff -u -r6c041cc09388a1435dfc52f610e74fea864c143c -r950c2bc06cda222b149f4663db732cf1c4554dbe
--- Riskeer/GrassCoverErosionInwards/src/Riskeer.GrassCoverErosionInwards.Forms/Views/GrassCoverErosionInwardsCalculationRow.cs (.../GrassCoverErosionInwardsCalculationRow.cs) (revision 6c041cc09388a1435dfc52f610e74fea864c143c)
+++ Riskeer/GrassCoverErosionInwards/src/Riskeer.GrassCoverErosionInwards.Forms/Views/GrassCoverErosionInwardsCalculationRow.cs (.../GrassCoverErosionInwardsCalculationRow.cs) (revision 950c2bc06cda222b149f4663db732cf1c4554dbe)
@@ -47,28 +47,28 @@
///
/// Creates a new instance of .
///
- /// The this row contains.
+ /// The this row contains.
/// The handler responsible for handling effects of a property change.
/// Thrown when any parameter is null.
- public GrassCoverErosionInwardsCalculationRow(GrassCoverErosionInwardsCalculationScenario grassCoverErosionInwardsCalculationScenario,
+ public GrassCoverErosionInwardsCalculationRow(GrassCoverErosionInwardsCalculationScenario calculationScenario,
IObservablePropertyChangeHandler handler)
{
- if (grassCoverErosionInwardsCalculationScenario == null)
+ if (calculationScenario == null)
{
- throw new ArgumentNullException(nameof(grassCoverErosionInwardsCalculationScenario));
+ throw new ArgumentNullException(nameof(calculationScenario));
}
if (handler == null)
{
throw new ArgumentNullException(nameof(handler));
}
- GrassCoverErosionInwardsCalculationScenario = grassCoverErosionInwardsCalculationScenario;
+ GrassCoverErosionInwardsCalculationScenario = calculationScenario;
propertyChangeHandler = handler;
ColumnStateDefinitions = new Dictionary();
CreateColumnStateDefinitions();
UpdateUseBreakWaterColumnStateDefinitions();
- UpdateUseUseForeshoreColumnStateDefinitions();
+ UpdateUseForeshoreColumnStateDefinitions();
}
///
@@ -81,10 +81,7 @@
///
public string Name
{
- get
- {
- return GrassCoverErosionInwardsCalculationScenario.Name;
- }
+ get => GrassCoverErosionInwardsCalculationScenario.Name;
set
{
GrassCoverErosionInwardsCalculationScenario.Name = value;
@@ -123,10 +120,7 @@
///
public DataGridViewComboBoxItemWrapper DikeProfile
{
- get
- {
- return new DataGridViewComboBoxItemWrapper(GrassCoverErosionInwardsCalculationScenario.InputParameters.DikeProfile);
- }
+ get => new DataGridViewComboBoxItemWrapper(GrassCoverErosionInwardsCalculationScenario.InputParameters.DikeProfile);
set
{
DikeProfile valueToSet = value?.WrappedObject;
@@ -142,10 +136,7 @@
///
public bool UseBreakWater
{
- get
- {
- return GrassCoverErosionInwardsCalculationScenario.InputParameters.UseBreakWater;
- }
+ get => GrassCoverErosionInwardsCalculationScenario.InputParameters.UseBreakWater;
set
{
if (!GrassCoverErosionInwardsCalculationScenario.InputParameters.UseBreakWater.Equals(value))
@@ -161,10 +152,7 @@
///
public BreakWaterType BreakWaterType
{
- get
- {
- return GrassCoverErosionInwardsCalculationScenario.InputParameters.BreakWater.Type;
- }
+ get => GrassCoverErosionInwardsCalculationScenario.InputParameters.BreakWater.Type;
set
{
if (!GrassCoverErosionInwardsCalculationScenario.InputParameters.BreakWater.Type.Equals(value))
@@ -179,10 +167,7 @@
///
public RoundedDouble BreakWaterHeight
{
- get
- {
- return GrassCoverErosionInwardsCalculationScenario.InputParameters.BreakWater.Height;
- }
+ get => GrassCoverErosionInwardsCalculationScenario.InputParameters.BreakWater.Height;
set
{
if (!GrassCoverErosionInwardsCalculationScenario.InputParameters.BreakWater.Height.Equals(value))
@@ -197,16 +182,13 @@
///
public bool UseForeShoreGeometry
{
- get
- {
- return GrassCoverErosionInwardsCalculationScenario.InputParameters.UseForeshore;
- }
+ get => GrassCoverErosionInwardsCalculationScenario.InputParameters.UseForeshore;
set
{
if (!GrassCoverErosionInwardsCalculationScenario.InputParameters.UseForeshore.Equals(value))
{
PropertyChangeHelper.ChangePropertyAndNotify(() => GrassCoverErosionInwardsCalculationScenario.InputParameters.UseForeshore = value, propertyChangeHandler);
- UpdateUseUseForeshoreColumnStateDefinitions();
+ UpdateUseForeshoreColumnStateDefinitions();
}
}
}
@@ -216,10 +198,7 @@
///
public RoundedDouble DikeHeight
{
- get
- {
- return GrassCoverErosionInwardsCalculationScenario.InputParameters.DikeHeight;
- }
+ get => GrassCoverErosionInwardsCalculationScenario.InputParameters.DikeHeight;
set
{
if (!GrassCoverErosionInwardsCalculationScenario.InputParameters.DikeHeight.Equals(value))
@@ -234,10 +213,7 @@
///
public RoundedDouble MeanCriticalFlowRate
{
- get
- {
- return GrassCoverErosionInwardsCalculationScenario.InputParameters.CriticalFlowRate.Mean;
- }
+ get => GrassCoverErosionInwardsCalculationScenario.InputParameters.CriticalFlowRate.Mean;
set
{
if (!GrassCoverErosionInwardsCalculationScenario.InputParameters.CriticalFlowRate.Mean.Equals(value))
@@ -252,10 +228,7 @@
///
public RoundedDouble StandardDeviationCriticalFlowRate
{
- get
- {
- return GrassCoverErosionInwardsCalculationScenario.InputParameters.CriticalFlowRate.StandardDeviation;
- }
+ get => GrassCoverErosionInwardsCalculationScenario.InputParameters.CriticalFlowRate.StandardDeviation;
set
{
if (!GrassCoverErosionInwardsCalculationScenario.InputParameters.CriticalFlowRate.StandardDeviation.Equals(value))
@@ -288,7 +261,7 @@
}
}
- private void UpdateUseUseForeshoreColumnStateDefinitions()
+ private void UpdateUseForeshoreColumnStateDefinitions()
{
DikeProfile dikeProfileForeshoreGeometry = GrassCoverErosionInwardsCalculationScenario.InputParameters.DikeProfile;
if (dikeProfileForeshoreGeometry == null || !dikeProfileForeshoreGeometry.ForeshoreGeometry.Any())
Index: Riskeer/GrassCoverErosionInwards/src/Riskeer.GrassCoverErosionInwards.Forms/Views/GrassCoverErosionInwardsCalculationsView.Designer.cs
===================================================================
diff -u -r9535d4151770fb6394fe00e56745d7b9ad0fe459 -r950c2bc06cda222b149f4663db732cf1c4554dbe
--- Riskeer/GrassCoverErosionInwards/src/Riskeer.GrassCoverErosionInwards.Forms/Views/GrassCoverErosionInwardsCalculationsView.Designer.cs (.../GrassCoverErosionInwardsCalculationsView.Designer.cs) (revision 9535d4151770fb6394fe00e56745d7b9ad0fe459)
+++ Riskeer/GrassCoverErosionInwards/src/Riskeer.GrassCoverErosionInwards.Forms/Views/GrassCoverErosionInwardsCalculationsView.Designer.cs (.../GrassCoverErosionInwardsCalculationsView.Designer.cs) (revision 950c2bc06cda222b149f4663db732cf1c4554dbe)
@@ -38,7 +38,7 @@
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(GrassCoverErosionInwardsCalculationsView));
this.tableLayoutPanelUserControl = new System.Windows.Forms.TableLayoutPanel();
- this.label1 = new System.Windows.Forms.Label();
+ this.warningMessageLabel = new System.Windows.Forms.Label();
this.splitContainer = new System.Windows.Forms.SplitContainer();
this.tableLayoutPanelListBox = new System.Windows.Forms.TableLayoutPanel();
this.listBox = new System.Windows.Forms.ListBox();
@@ -59,15 +59,14 @@
// tableLayoutPanelUserControl
//
resources.ApplyResources(this.tableLayoutPanelUserControl, "tableLayoutPanelUserControl");
- this.tableLayoutPanelUserControl.Controls.Add(this.label1, 0, 2);
this.tableLayoutPanelUserControl.Controls.Add(this.splitContainer, 0, 0);
this.tableLayoutPanelUserControl.Controls.Add(this.buttonGenerateCalculations, 0, 1);
this.tableLayoutPanelUserControl.Name = "tableLayoutPanelUserControl";
//
- // label1
+ // warningMessageLabel
//
- resources.ApplyResources(this.label1, "label1");
- this.label1.Name = "label1";
+ resources.ApplyResources(this.warningMessageLabel, "warningMessageLabel");
+ this.warningMessageLabel.Name = "warningMessageLabel";
//
// splitContainer
//
@@ -104,6 +103,7 @@
// tableLayoutPanelDataGrid
//
resources.ApplyResources(this.tableLayoutPanelDataGrid, "tableLayoutPanelDataGrid");
+ this.tableLayoutPanelDataGrid.Controls.Add(this.warningMessageLabel, 0, 2);
this.tableLayoutPanelDataGrid.Controls.Add(this.labelCalculations, 0, 0);
this.tableLayoutPanelDataGrid.Controls.Add(this.dataGridViewControl, 0, 1);
this.tableLayoutPanelDataGrid.Name = "tableLayoutPanelDataGrid";
@@ -158,6 +158,6 @@
private System.Windows.Forms.Label labelCalculations;
private Core.Common.Controls.DataGrid.DataGridViewControl dataGridViewControl;
private System.Windows.Forms.Button buttonGenerateCalculations;
- private System.Windows.Forms.Label label1;
+ private System.Windows.Forms.Label warningMessageLabel;
}
}
Index: Riskeer/GrassCoverErosionInwards/src/Riskeer.GrassCoverErosionInwards.Forms/Views/GrassCoverErosionInwardsCalculationsView.cs
===================================================================
diff -u -rba2bd8d63764da61fc0df342947616ee2c1c2af8 -r950c2bc06cda222b149f4663db732cf1c4554dbe
--- Riskeer/GrassCoverErosionInwards/src/Riskeer.GrassCoverErosionInwards.Forms/Views/GrassCoverErosionInwardsCalculationsView.cs (.../GrassCoverErosionInwardsCalculationsView.cs) (revision ba2bd8d63764da61fc0df342947616ee2c1c2af8)
+++ Riskeer/GrassCoverErosionInwards/src/Riskeer.GrassCoverErosionInwards.Forms/Views/GrassCoverErosionInwardsCalculationsView.cs (.../GrassCoverErosionInwardsCalculationsView.cs) (revision 950c2bc06cda222b149f4663db732cf1c4554dbe)
@@ -50,16 +50,16 @@
{
private const int selectableHydraulicBoundaryLocationColumnIndex = 1;
private const int selectableDikeProfileColumnIndex = 2;
- private readonly Observer grassCoverErosionInwardsFailureMechanismObserver;
+ private readonly Observer failureMechanismObserver;
private readonly Observer hydraulicBoundaryLocationsObserver;
private readonly Observer dikeProfilesObserver;
- private readonly RecursiveObserver grassCoverErosionInwardsInputObserver;
- private readonly RecursiveObserver grassCoverErosionInwardsCalculationScenarioObserver;
- private readonly RecursiveObserver grassCoverErosionInwardsCalculationGroupObserver;
+ private readonly RecursiveObserver inputObserver;
+ private readonly RecursiveObserver calculationScenarioObserver;
+ private readonly RecursiveObserver calculationGroupObserver;
private CalculationGroup calculationGroup;
private IAssessmentSection assessmentSection;
- private GrassCoverErosionInwardsFailureMechanism grassCoverErosionInwardsFailureMechanism;
+ private GrassCoverErosionInwardsFailureMechanism failureMechanism;
public event EventHandler SelectionChanged;
@@ -72,29 +72,26 @@
InitializeDataGridView();
InitializeListBox();
- grassCoverErosionInwardsFailureMechanismObserver = new Observer(OnGrassCoverErosionInwardsFailureMechanismUpdate);
+ failureMechanismObserver = new Observer(OnFailureMechanismUpdate);
hydraulicBoundaryLocationsObserver = new Observer(UpdateSelectableHydraulicBoundaryLocationsColumn);
dikeProfilesObserver = new Observer(UpdateDikeProfilesColumn);
// The concat is needed to observe the input of calculations in child groups.
- grassCoverErosionInwardsInputObserver = new RecursiveObserver(UpdateDataGridViewDataSource, pcg => pcg.Children.Concat