Index: Application/Ringtoets/src/Application.Ringtoets.Storage/Create/ClosingStructures/ClosingStructureCreateExtensions.cs =================================================================== diff -u -ra3906d39b799530a0e38750705dc49abaa037c9d -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Application/Ringtoets/src/Application.Ringtoets.Storage/Create/ClosingStructures/ClosingStructureCreateExtensions.cs (.../ClosingStructureCreateExtensions.cs) (revision a3906d39b799530a0e38750705dc49abaa037c9d) +++ Application/Ringtoets/src/Application.Ringtoets.Storage/Create/ClosingStructures/ClosingStructureCreateExtensions.cs (.../ClosingStructureCreateExtensions.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -76,7 +76,7 @@ CriticalOvertoppingDischargeCoefficientOfVariation = structure.CriticalOvertoppingDischarge.CoefficientOfVariation.Value.ToNaNAsNull(), FlowWidthAtBottomProtectionMean = structure.FlowWidthAtBottomProtection.Mean.Value.ToNaNAsNull(), FlowWidthAtBottomProtectionStandardDeviation = structure.FlowWidthAtBottomProtection.StandardDeviation.Value.ToNaNAsNull(), - ProbabilityOpenStructureBeforeFlooding = structure.ProbabilityOpenStructureBeforeFlooding.ToNaNAsNull(), + ProbabilityOrFrequencyOpenStructureBeforeFlooding = structure.ProbabilityOrFrequencyOpenStructureBeforeFlooding.ToNaNAsNull(), FailureProbabilityOpenStructure = structure.FailureProbabilityOpenStructure.ToNaNAsNull(), IdenticalApertures = structure.IdenticalApertures, FailureProbabilityReparation = structure.FailureProbabilityReparation.ToNaNAsNull(), Index: Application/Ringtoets/src/Application.Ringtoets.Storage/Create/StructuresCalculationCreateExtensions.cs =================================================================== diff -u -rb4e3629ea2130359117dd403af8db3c8ae0c680b -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Application/Ringtoets/src/Application.Ringtoets.Storage/Create/StructuresCalculationCreateExtensions.cs (.../StructuresCalculationCreateExtensions.cs) (revision b4e3629ea2130359117dd403af8db3c8ae0c680b) +++ Application/Ringtoets/src/Application.Ringtoets.Storage/Create/StructuresCalculationCreateExtensions.cs (.../StructuresCalculationCreateExtensions.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -156,7 +156,7 @@ entity.LevelCrestStructureNotClosingMean = input.LevelCrestStructureNotClosing.Mean.Value.ToNaNAsNull(); entity.LevelCrestStructureNotClosingStandardDeviation = input.LevelCrestStructureNotClosing.StandardDeviation.Value.ToNaNAsNull(); - entity.ProbabilityOpenStructureBeforeFlooding = input.ProbabilityOpenStructureBeforeFlooding; + entity.ProbabilityOrFrequencyOpenStructureBeforeFlooding = input.ProbabilityOrFrequencyOpenStructureBeforeFlooding; } private static void SetOutputEntity(StructuresCalculation calculation, Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/ClosingStructureEntity.cs =================================================================== diff -u -rfcc2776f9c6b0e607a661c46b83b54de514f175e -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/ClosingStructureEntity.cs (.../ClosingStructureEntity.cs) (revision fcc2776f9c6b0e607a661c46b83b54de514f175e) +++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/ClosingStructureEntity.cs (.../ClosingStructureEntity.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -67,7 +67,7 @@ public Nullable CriticalOvertoppingDischargeCoefficientOfVariation { get; set; } public Nullable FlowWidthAtBottomProtectionMean { get; set; } public Nullable FlowWidthAtBottomProtectionStandardDeviation { get; set; } - public Nullable ProbabilityOpenStructureBeforeFlooding { get; set; } + public Nullable ProbabilityOrFrequencyOpenStructureBeforeFlooding { get; set; } public Nullable FailureProbabilityOpenStructure { get; set; } public int IdenticalApertures { get; set; } public Nullable FailureProbabilityReparation { get; set; } Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/ClosingStructuresCalculationEntity.cs =================================================================== diff -u -rfcc2776f9c6b0e607a661c46b83b54de514f175e -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/ClosingStructuresCalculationEntity.cs (.../ClosingStructuresCalculationEntity.cs) (revision fcc2776f9c6b0e607a661c46b83b54de514f175e) +++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/ClosingStructuresCalculationEntity.cs (.../ClosingStructuresCalculationEntity.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -74,7 +74,7 @@ public Nullable CriticalOvertoppingDischargeCoefficientOfVariation { get; set; } public Nullable FlowWidthAtBottomProtectionMean { get; set; } public Nullable FlowWidthAtBottomProtectionStandardDeviation { get; set; } - public double ProbabilityOpenStructureBeforeFlooding { get; set; } + public double ProbabilityOrFrequencyOpenStructureBeforeFlooding { get; set; } public double FailureProbabilityOpenStructure { get; set; } public int IdenticalApertures { get; set; } public double FailureProbabilityReparation { get; set; } Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/DatabaseStructure.sql =================================================================== diff -u -rfcc2776f9c6b0e607a661c46b83b54de514f175e -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/DatabaseStructure.sql (.../DatabaseStructure.sql) (revision fcc2776f9c6b0e607a661c46b83b54de514f175e) +++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/DatabaseStructure.sql (.../DatabaseStructure.sql) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -1,6 +1,6 @@ /* ---------------------------------------------------- */ /* Generated by Enterprise Architect Version 12.0 */ -/* Created On : 12-Dec-2016 2:18:00 PM */ +/* Created On : 12-dec-2016 16:11:37 */ /* DBMS : SQLite */ /* ---------------------------------------------------- */ @@ -1083,7 +1083,7 @@ 'CriticalOvertoppingDischargeCoefficientOfVariation' REAL, 'FlowWidthAtBottomProtectionMean' REAL, 'FlowWidthAtBottomProtectionStandardDeviation' REAL, - 'ProbabilityOpenStructureBeforeFlooding' REAL, + 'ProbabilityOrFrequencyOpenStructureBeforeFlooding' REAL, 'FailureProbabilityOpenStructure' REAL, 'IdenticalApertures' INT (4) NOT NULL, 'FailureProbabilityReparation' REAL, @@ -1126,7 +1126,7 @@ 'CriticalOvertoppingDischargeCoefficientOfVariation' REAL, 'FlowWidthAtBottomProtectionMean' REAL, 'FlowWidthAtBottomProtectionStandardDeviation' REAL, - 'ProbabilityOpenStructureBeforeFlooding' REAL NOT NULL, + 'ProbabilityOrFrequencyOpenStructureBeforeFlooding' REAL NOT NULL, 'FailureProbabilityOpenStructure' REAL NOT NULL, 'IdenticalApertures' INT (4) NOT NULL, 'FailureProbabilityReparation' REAL NOT NULL, Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.Designer.cs =================================================================== diff -u -rbfe36d6bae8c85e941d20cd6f150f022445d3ac2 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.Designer.cs (.../RingtoetsEntities.Designer.cs) (revision bfe36d6bae8c85e941d20cd6f150f022445d3ac2) +++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.Designer.cs (.../RingtoetsEntities.Designer.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -1,25 +1,4 @@ -// Copyright (C) Stichting Deltares 2016. All rights reserved. -// -// This file is part of Ringtoets. -// -// Ringtoets 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. - -// T4 code generation is enabled for model 'D:\Projects\WTILatestTrunk\Application\Ringtoets\src\Application.Ringtoets.Storage\DbContext\RingtoetsEntities.edmx'. +// T4 code generation is enabled for model 'D:\Clean_WTI2017\Application\Ringtoets\src\Application.Ringtoets.Storage\DbContext\RingtoetsEntities.edmx'. // To enable legacy code generation, change the value of the 'Code Generation Strategy' designer // property to 'Legacy ObjectContext'. This property is available in the Properties Window when the model // is open in the designer. Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.edmx =================================================================== diff -u -rfcc2776f9c6b0e607a661c46b83b54de514f175e -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.edmx (.../RingtoetsEntities.edmx) (revision fcc2776f9c6b0e607a661c46b83b54de514f175e) +++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.edmx (.../RingtoetsEntities.edmx) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -4,7 +4,7 @@ - + @@ -71,7 +71,7 @@ - + @@ -121,7 +121,7 @@ - + @@ -2924,7 +2924,7 @@ - + @@ -2977,7 +2977,7 @@ - + @@ -5083,7 +5083,7 @@ - + @@ -5135,7 +5135,7 @@ - + Index: Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.edmx.diagram =================================================================== diff -u -rfcc2776f9c6b0e607a661c46b83b54de514f175e -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.edmx.diagram (.../RingtoetsEntities.edmx.diagram) (revision fcc2776f9c6b0e607a661c46b83b54de514f175e) +++ Application/Ringtoets/src/Application.Ringtoets.Storage/DbContext/RingtoetsEntities.edmx.diagram (.../RingtoetsEntities.edmx.diagram) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -7,67 +7,67 @@ - - - - - - - - + + + + + + + + - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + - - - - - - - - - + + + + + + + + + - - - - + + + + - - - - - - - - - - + + + + + + + + + + - - - - + + + + Index: Application/Ringtoets/src/Application.Ringtoets.Storage/Read/ClosingStructures/ClosingStructureEntityReadExtensions.cs =================================================================== diff -u -ra3906d39b799530a0e38750705dc49abaa037c9d -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Application/Ringtoets/src/Application.Ringtoets.Storage/Read/ClosingStructures/ClosingStructureEntityReadExtensions.cs (.../ClosingStructureEntityReadExtensions.cs) (revision a3906d39b799530a0e38750705dc49abaa037c9d) +++ Application/Ringtoets/src/Application.Ringtoets.Storage/Read/ClosingStructures/ClosingStructureEntityReadExtensions.cs (.../ClosingStructureEntityReadExtensions.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -103,7 +103,7 @@ Mean = (RoundedDouble) entity.FlowWidthAtBottomProtectionMean.ToNullAsNaN(), StandardDeviation = (RoundedDouble) entity.FlowWidthAtBottomProtectionStandardDeviation.ToNullAsNaN() }, - ProbabilityOpenStructureBeforeFlooding = entity.ProbabilityOpenStructureBeforeFlooding.ToNullAsNaN(), + ProbabilityOrFrequencyOpenStructureBeforeFlooding = entity.ProbabilityOrFrequencyOpenStructureBeforeFlooding.ToNullAsNaN(), FailureProbabilityOpenStructure = entity.FailureProbabilityOpenStructure.ToNullAsNaN(), IdenticalApertures = entity.IdenticalApertures, FailureProbabilityReparation = entity.FailureProbabilityReparation.ToNullAsNaN(), Index: Application/Ringtoets/src/Application.Ringtoets.Storage/Read/ClosingStructures/ClosingStructuresCalculationEntityReadExtensions.cs =================================================================== diff -u -rb4e3629ea2130359117dd403af8db3c8ae0c680b -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Application/Ringtoets/src/Application.Ringtoets.Storage/Read/ClosingStructures/ClosingStructuresCalculationEntityReadExtensions.cs (.../ClosingStructuresCalculationEntityReadExtensions.cs) (revision b4e3629ea2130359117dd403af8db3c8ae0c680b) +++ Application/Ringtoets/src/Application.Ringtoets.Storage/Read/ClosingStructures/ClosingStructuresCalculationEntityReadExtensions.cs (.../ClosingStructuresCalculationEntityReadExtensions.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -94,7 +94,7 @@ inputParameters.IdenticalApertures = entity.IdenticalApertures; inputParameters.LevelCrestStructureNotClosing.Mean = (RoundedDouble) entity.LevelCrestStructureNotClosingMean.ToNullAsNaN(); inputParameters.LevelCrestStructureNotClosing.StandardDeviation = (RoundedDouble) entity.LevelCrestStructureNotClosingStandardDeviation.ToNullAsNaN(); - inputParameters.ProbabilityOpenStructureBeforeFlooding = entity.ProbabilityOpenStructureBeforeFlooding; + inputParameters.ProbabilityOrFrequencyOpenStructureBeforeFlooding = entity.ProbabilityOrFrequencyOpenStructureBeforeFlooding; } private static void ReadOutput(StructuresCalculation calculation, ClosingStructuresCalculationEntity entity) Index: Application/Ringtoets/test/Application.Ringtoets.Storage.Test/Create/ClosingStructures/ClosingStructureCreateExtensionsTest.cs =================================================================== diff -u -ra3906d39b799530a0e38750705dc49abaa037c9d -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Application/Ringtoets/test/Application.Ringtoets.Storage.Test/Create/ClosingStructures/ClosingStructureCreateExtensionsTest.cs (.../ClosingStructureCreateExtensionsTest.cs) (revision a3906d39b799530a0e38750705dc49abaa037c9d) +++ Application/Ringtoets/test/Application.Ringtoets.Storage.Test/Create/ClosingStructures/ClosingStructureCreateExtensionsTest.cs (.../ClosingStructureCreateExtensionsTest.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -87,7 +87,7 @@ Assert.AreEqual(structure.CriticalOvertoppingDischarge.CoefficientOfVariation.Value, entity.CriticalOvertoppingDischargeCoefficientOfVariation); Assert.AreEqual(structure.FlowWidthAtBottomProtection.Mean.Value, entity.FlowWidthAtBottomProtectionMean); Assert.AreEqual(structure.FlowWidthAtBottomProtection.StandardDeviation.Value, entity.FlowWidthAtBottomProtectionStandardDeviation); - Assert.AreEqual(structure.ProbabilityOpenStructureBeforeFlooding, entity.ProbabilityOpenStructureBeforeFlooding); + Assert.AreEqual(structure.ProbabilityOrFrequencyOpenStructureBeforeFlooding, entity.ProbabilityOrFrequencyOpenStructureBeforeFlooding); Assert.AreEqual(structure.FailureProbabilityOpenStructure, entity.FailureProbabilityOpenStructure); Assert.AreEqual(structure.IdenticalApertures, entity.IdenticalApertures); Assert.AreEqual(structure.FailureProbabilityReparation, entity.FailureProbabilityReparation); @@ -152,7 +152,7 @@ Mean = RoundedDouble.NaN, StandardDeviation = RoundedDouble.NaN }, - ProbabilityOpenStructureBeforeFlooding = double.NaN, + ProbabilityOrFrequencyOpenStructureBeforeFlooding = double.NaN, FailureProbabilityOpenStructure = double.NaN, FailureProbabilityReparation = double.NaN }); @@ -183,7 +183,7 @@ Assert.IsNull(entity.CriticalOvertoppingDischargeCoefficientOfVariation); Assert.IsNull(entity.FlowWidthAtBottomProtectionMean); Assert.IsNull(entity.FlowWidthAtBottomProtectionStandardDeviation); - Assert.IsNull(entity.ProbabilityOpenStructureBeforeFlooding); + Assert.IsNull(entity.ProbabilityOrFrequencyOpenStructureBeforeFlooding); Assert.IsNull(entity.FailureProbabilityOpenStructure); Assert.IsNull(entity.FailureProbabilityReparation); } Index: Application/Ringtoets/test/Application.Ringtoets.Storage.Test/Create/StructuresCalculationCreateExtensionsTest.cs =================================================================== diff -u -re182f6f394aa75e739467a77e7bcacd9a8b25429 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Application/Ringtoets/test/Application.Ringtoets.Storage.Test/Create/StructuresCalculationCreateExtensionsTest.cs (.../StructuresCalculationCreateExtensionsTest.cs) (revision e182f6f394aa75e739467a77e7bcacd9a8b25429) +++ Application/Ringtoets/test/Application.Ringtoets.Storage.Test/Create/StructuresCalculationCreateExtensionsTest.cs (.../StructuresCalculationCreateExtensionsTest.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -480,7 +480,7 @@ Mean = (RoundedDouble) random.NextDouble(), StandardDeviation = (RoundedDouble) random.NextDouble() }, - ProbabilityOpenStructureBeforeFlooding = (RoundedDouble) random.NextDouble() + ProbabilityOrFrequencyOpenStructureBeforeFlooding = (RoundedDouble) random.NextDouble() } }; @@ -532,7 +532,7 @@ Assert.AreEqual(inputParameters.IdenticalApertures, entity.IdenticalApertures); Assert.AreEqual(inputParameters.LevelCrestStructureNotClosing.Mean.Value, entity.LevelCrestStructureNotClosingMean); Assert.AreEqual(inputParameters.LevelCrestStructureNotClosing.StandardDeviation.Value, entity.LevelCrestStructureNotClosingStandardDeviation); - Assert.AreEqual(inputParameters.ProbabilityOpenStructureBeforeFlooding, entity.ProbabilityOpenStructureBeforeFlooding); + Assert.AreEqual(inputParameters.ProbabilityOrFrequencyOpenStructureBeforeFlooding, entity.ProbabilityOrFrequencyOpenStructureBeforeFlooding); Assert.AreEqual(order, entity.Order); CollectionAssert.IsEmpty(entity.ClosingStructuresOutputEntities); Index: Application/Ringtoets/test/Application.Ringtoets.Storage.Test/IntegrationTests/StorageSqLiteIntegrationTest.cs =================================================================== diff -u -rd56bec747401ad6676fac64af5eef6d5fd89c47c -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Application/Ringtoets/test/Application.Ringtoets.Storage.Test/IntegrationTests/StorageSqLiteIntegrationTest.cs (.../StorageSqLiteIntegrationTest.cs) (revision d56bec747401ad6676fac64af5eef6d5fd89c47c) +++ Application/Ringtoets/test/Application.Ringtoets.Storage.Test/IntegrationTests/StorageSqLiteIntegrationTest.cs (.../StorageSqLiteIntegrationTest.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -1099,7 +1099,7 @@ DistributionAssert.AreEqual(expectedClosingStructure.AreaFlowApertures, actualClosingStructure.AreaFlowApertures); DistributionAssert.AreEqual(expectedClosingStructure.CriticalOvertoppingDischarge, actualClosingStructure.CriticalOvertoppingDischarge); DistributionAssert.AreEqual(expectedClosingStructure.FlowWidthAtBottomProtection, actualClosingStructure.FlowWidthAtBottomProtection); - Assert.AreEqual(expectedClosingStructure.ProbabilityOpenStructureBeforeFlooding, actualClosingStructure.ProbabilityOpenStructureBeforeFlooding); + Assert.AreEqual(expectedClosingStructure.ProbabilityOrFrequencyOpenStructureBeforeFlooding, actualClosingStructure.ProbabilityOrFrequencyOpenStructureBeforeFlooding); Assert.AreEqual(expectedClosingStructure.FailureProbabilityOpenStructure, actualClosingStructure.FailureProbabilityOpenStructure); Assert.AreEqual(expectedClosingStructure.IdenticalApertures, actualClosingStructure.IdenticalApertures); Assert.AreEqual(expectedClosingStructure.FailureProbabilityReparation, actualClosingStructure.FailureProbabilityReparation); @@ -1149,7 +1149,7 @@ Assert.AreEqual(expectedInput.FailureProbabilityReparation, actualInput.FailureProbabilityReparation); Assert.AreEqual(expectedInput.IdenticalApertures, actualInput.IdenticalApertures); DistributionAssert.AreEqual(expectedInput.LevelCrestStructureNotClosing, actualInput.LevelCrestStructureNotClosing); - Assert.AreEqual(expectedInput.ProbabilityOpenStructureBeforeFlooding, actualInput.ProbabilityOpenStructureBeforeFlooding); + Assert.AreEqual(expectedInput.ProbabilityOrFrequencyOpenStructureBeforeFlooding, actualInput.ProbabilityOrFrequencyOpenStructureBeforeFlooding); } #endregion Index: Application/Ringtoets/test/Application.Ringtoets.Storage.Test/Read/ClosingStructures/ClosingStructureEntityReadExtensionsTest.cs =================================================================== diff -u -r86ce17cdf5cf329f4d5bcd444320994fead52294 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Application/Ringtoets/test/Application.Ringtoets.Storage.Test/Read/ClosingStructures/ClosingStructureEntityReadExtensionsTest.cs (.../ClosingStructureEntityReadExtensionsTest.cs) (revision 86ce17cdf5cf329f4d5bcd444320994fead52294) +++ Application/Ringtoets/test/Application.Ringtoets.Storage.Test/Read/ClosingStructures/ClosingStructureEntityReadExtensionsTest.cs (.../ClosingStructureEntityReadExtensionsTest.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -98,7 +98,7 @@ CriticalOvertoppingDischargeCoefficientOfVariation = 19.19, FlowWidthAtBottomProtectionMean = 20.20, FlowWidthAtBottomProtectionStandardDeviation = 21.21, - ProbabilityOpenStructureBeforeFlooding = 22.22, + ProbabilityOrFrequencyOpenStructureBeforeFlooding = 22.22, FailureProbabilityOpenStructure = 23.23, IdenticalApertures = 24, FailureProbabilityReparation = 25.25, @@ -134,7 +134,7 @@ Assert.AreEqual(entity.CriticalOvertoppingDischargeCoefficientOfVariation, structure.CriticalOvertoppingDischarge.CoefficientOfVariation.Value); Assert.AreEqual(entity.FlowWidthAtBottomProtectionMean, structure.FlowWidthAtBottomProtection.Mean.Value); Assert.AreEqual(entity.FlowWidthAtBottomProtectionStandardDeviation, structure.FlowWidthAtBottomProtection.StandardDeviation.Value); - Assert.AreEqual(entity.ProbabilityOpenStructureBeforeFlooding, structure.ProbabilityOpenStructureBeforeFlooding); + Assert.AreEqual(entity.ProbabilityOrFrequencyOpenStructureBeforeFlooding, structure.ProbabilityOrFrequencyOpenStructureBeforeFlooding); Assert.AreEqual(entity.FailureProbabilityOpenStructure, structure.FailureProbabilityOpenStructure); Assert.AreEqual(entity.IdenticalApertures, structure.IdenticalApertures); Assert.AreEqual(entity.FailureProbabilityReparation, structure.FailureProbabilityReparation); @@ -172,7 +172,7 @@ CriticalOvertoppingDischargeCoefficientOfVariation = null, FlowWidthAtBottomProtectionMean = null, FlowWidthAtBottomProtectionStandardDeviation = null, - ProbabilityOpenStructureBeforeFlooding = null, + ProbabilityOrFrequencyOpenStructureBeforeFlooding = null, FailureProbabilityOpenStructure = null }; @@ -204,7 +204,7 @@ Assert.IsNaN(structure.CriticalOvertoppingDischarge.CoefficientOfVariation); Assert.IsNaN(structure.FlowWidthAtBottomProtection.Mean); Assert.IsNaN(structure.FlowWidthAtBottomProtection.StandardDeviation); - Assert.IsNaN(structure.ProbabilityOpenStructureBeforeFlooding); + Assert.IsNaN(structure.ProbabilityOrFrequencyOpenStructureBeforeFlooding); Assert.IsNaN(structure.FailureProbabilityOpenStructure); Assert.IsNaN(structure.FailureProbabilityReparation); } Index: Application/Ringtoets/test/Application.Ringtoets.Storage.Test/Read/ClosingStructures/ClosingStructuresCalculationEntityReadExtensionsTest.cs =================================================================== diff -u -re182f6f394aa75e739467a77e7bcacd9a8b25429 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Application/Ringtoets/test/Application.Ringtoets.Storage.Test/Read/ClosingStructures/ClosingStructuresCalculationEntityReadExtensionsTest.cs (.../ClosingStructuresCalculationEntityReadExtensionsTest.cs) (revision e182f6f394aa75e739467a77e7bcacd9a8b25429) +++ Application/Ringtoets/test/Application.Ringtoets.Storage.Test/Read/ClosingStructures/ClosingStructuresCalculationEntityReadExtensionsTest.cs (.../ClosingStructuresCalculationEntityReadExtensionsTest.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -110,7 +110,7 @@ IdenticalApertures = 27, LevelCrestStructureNotClosingMean = 28.28, LevelCrestStructureNotClosingStandardDeviation = 29.29, - ProbabilityOpenStructureBeforeFlooding = 0.30 + ProbabilityOrFrequencyOpenStructureBeforeFlooding = 0.30 }; var collector = new ReadConversionCollector(); @@ -159,7 +159,7 @@ Assert.AreEqual(entity.IdenticalApertures, inputParameters.IdenticalApertures); Assert.AreEqual(entity.LevelCrestStructureNotClosingMean, inputParameters.LevelCrestStructureNotClosing.Mean.Value); Assert.AreEqual(entity.LevelCrestStructureNotClosingStandardDeviation, inputParameters.LevelCrestStructureNotClosing.StandardDeviation.Value); - Assert.AreEqual(entity.ProbabilityOpenStructureBeforeFlooding, inputParameters.ProbabilityOpenStructureBeforeFlooding); + Assert.AreEqual(entity.ProbabilityOrFrequencyOpenStructureBeforeFlooding, inputParameters.ProbabilityOrFrequencyOpenStructureBeforeFlooding); Assert.IsFalse(calculation.HasOutput); } Index: Demo/Ringtoets/src/Demo.Ringtoets/Commands/AddNewDemoAssessmentSectionCommand.cs =================================================================== diff -u -r371faaa68a19c11999b39f605b977bf078c040e7 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Demo/Ringtoets/src/Demo.Ringtoets/Commands/AddNewDemoAssessmentSectionCommand.cs (.../AddNewDemoAssessmentSectionCommand.cs) (revision 371faaa68a19c11999b39f605b977bf078c040e7) +++ Demo/Ringtoets/src/Demo.Ringtoets/Commands/AddNewDemoAssessmentSectionCommand.cs (.../AddNewDemoAssessmentSectionCommand.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -503,7 +503,7 @@ Mean = (RoundedDouble) 25.0, StandardDeviation = (RoundedDouble) 0.05 }, - ProbabilityOpenStructureBeforeFlooding = 1.0, + ProbabilityOrFrequencyOpenStructureBeforeFlooding = 1.0, FailureProbabilityOpenStructure = 0.1, IdenticalApertures = 4, FailureProbabilityReparation = 1.0, Index: Demo/Ringtoets/test/Demo.Ringtoets.Test/Commands/AddNewDemoAssessmentSectionCommandTest.cs =================================================================== diff -u -re60dbf2fd41434270cad4efba20446e19ede0d2e -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Demo/Ringtoets/test/Demo.Ringtoets.Test/Commands/AddNewDemoAssessmentSectionCommandTest.cs (.../AddNewDemoAssessmentSectionCommandTest.cs) (revision e60dbf2fd41434270cad4efba20446e19ede0d2e) +++ Demo/Ringtoets/test/Demo.Ringtoets.Test/Commands/AddNewDemoAssessmentSectionCommandTest.cs (.../AddNewDemoAssessmentSectionCommandTest.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -356,7 +356,7 @@ Assert.AreEqual(0.15, closingStructure.CriticalOvertoppingDischarge.CoefficientOfVariation.Value); Assert.AreEqual(25.0, closingStructure.FlowWidthAtBottomProtection.Mean.Value); Assert.AreEqual(0.05, closingStructure.FlowWidthAtBottomProtection.StandardDeviation.Value); - Assert.AreEqual(1.0, closingStructure.ProbabilityOpenStructureBeforeFlooding); + Assert.AreEqual(1.0, closingStructure.ProbabilityOrFrequencyOpenStructureBeforeFlooding); Assert.AreEqual(0.1, closingStructure.FailureProbabilityOpenStructure); Assert.AreEqual(4, closingStructure.IdenticalApertures); Assert.AreEqual(1.0, closingStructure.FailureProbabilityReparation); Index: Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Data/ClosingStructure.cs =================================================================== diff -u -r7d6e4c28a40fb056c182d0691dda2b2e88aeebfd -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Data/ClosingStructure.cs (.../ClosingStructure.cs) (revision 7d6e4c28a40fb056c182d0691dda2b2e88aeebfd) +++ Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Data/ClosingStructure.cs (.../ClosingStructure.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -20,6 +20,8 @@ // All rights reserved. using System; +using System.Collections.ObjectModel; +using System.Linq; using Ringtoets.Common.Data; using Ringtoets.Common.Data.Probabilistics; using BaseConstructionProperties = Ringtoets.Common.Data.StructureBase.ConstructionProperties; @@ -85,7 +87,7 @@ Mean = constructionProperties.FlowWidthAtBottomProtection.Mean, StandardDeviation = constructionProperties.FlowWidthAtBottomProtection.StandardDeviation }; - ProbabilityOpenStructureBeforeFlooding = constructionProperties.ProbabilityOpenStructureBeforeFlooding; + ProbabilityOrFrequencyOpenStructureBeforeFlooding = constructionProperties.ProbabilityOrFrequencyOpenStructureBeforeFlooding; FailureProbabilityOpenStructure = constructionProperties.FailureProbabilityOpenStructure; IdenticalApertures = constructionProperties.IdenticalApertures; FailureProbabilityReparation = constructionProperties.FailureProbabilityReparation; @@ -147,10 +149,13 @@ public LogNormalDistribution FlowWidthAtBottomProtection { get; private set; } /// - /// Gets the probability of the closing structure being open before flooding. + /// Gets the probability or frequency of the closing structure being open before flooding. /// [1/year] /// - public double ProbabilityOpenStructureBeforeFlooding { get; private set; } + /// Because this property can also be used to denote a frequency, there + /// is no guarantee that this property returns a value in the range [0.0, 1.0] + /// nor that formal rules of probability apply. + public double ProbabilityOrFrequencyOpenStructureBeforeFlooding { get; private set; } /// /// Gets the probability of failing to close the closing structure. @@ -250,10 +255,13 @@ public LogNormalDistribution FlowWidthAtBottomProtection { get; private set; } /// - /// Gets or sets the probability of the closing structure being open before flooding. + /// Gets the probability or frequency of the closing structure being open before flooding. /// [1/year] /// - public double ProbabilityOpenStructureBeforeFlooding { get; set; } + /// Because this property can also be used to denote a frequency, there + /// is no guarantee that this property returns a value in the range [0.0, 1.0] + /// nor that formal rules of probability apply. + public double ProbabilityOrFrequencyOpenStructureBeforeFlooding { get; set; } /// /// Gets or sets the probability of failing to close the closing structure. Index: Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Data/ClosingStructuresInput.cs =================================================================== diff -u -r7a6c07ce4fcb7887319744836e0b513709187445 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Data/ClosingStructuresInput.cs (.../ClosingStructuresInput.cs) (revision 7a6c07ce4fcb7887319744836e0b513709187445) +++ Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Data/ClosingStructuresInput.cs (.../ClosingStructuresInput.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -21,6 +21,7 @@ using System; using Core.Common.Base.Data; +using Ringtoets.ClosingStructures.Data.Properties; using Ringtoets.Common.Data.Probabilistics; using Ringtoets.Common.Data.Structures; using RingtoetsCommonDataResources = Ringtoets.Common.Data.Properties.Resources; @@ -40,7 +41,7 @@ private RoundedDouble factorStormDurationOpenStructure; private double failureProbabilityOpenStructure; private double failureProbabilityReparation; - private double probabilityOpenStructureBeforeFlooding; + private double probabilityOrFrequencyOpenStructureBeforeFlooding; private RoundedDouble deviationWaveDirection; /// @@ -53,7 +54,7 @@ failureProbabilityOpenStructure = 0; failureProbabilityReparation = 0; - probabilityOpenStructureBeforeFlooding = 1.0; + probabilityOrFrequencyOpenStructureBeforeFlooding = 1.0; thresholdHeightOpenWeir = new NormalDistribution(2) { @@ -112,7 +113,7 @@ FailureProbabilityReparation = Structure.FailureProbabilityReparation; IdenticalApertures = Structure.IdenticalApertures; InsideWaterLevel = Structure.InsideWaterLevel; - ProbabilityOpenStructureBeforeFlooding = Structure.ProbabilityOpenStructureBeforeFlooding; + ProbabilityOrFrequencyOpenStructureBeforeFlooding = Structure.ProbabilityOrFrequencyOpenStructureBeforeFlooding; ThresholdHeightOpenWeir = Structure.ThresholdHeightOpenWeir; } } @@ -297,23 +298,22 @@ } /// - /// Gets or sets the failure probability of an open structure before flooding. + /// Gets or sets the failure probability/frequency of an open structure before flooding. /// - /// Thrown when the value of the probability - /// is not in the interval [0, 1]. - public double ProbabilityOpenStructureBeforeFlooding + /// Thrown when the value is negative. + public double ProbabilityOrFrequencyOpenStructureBeforeFlooding { get { - return probabilityOpenStructureBeforeFlooding; + return probabilityOrFrequencyOpenStructureBeforeFlooding; } set { - if (!ValidProbabilityValue(value)) + if (double.IsNaN(value) || value < 0) { - throw new ArgumentOutOfRangeException("value", RingtoetsCommonDataResources.FailureProbability_Value_needs_to_be_between_0_and_1); + throw new ArgumentOutOfRangeException("value", Resources.ClosingStructuresInput_ProbabilityOrFrequencyOpenStructureBeforeFlooding_Value_must_be_greater_or_equal_to_zero); } - probabilityOpenStructureBeforeFlooding = value; + probabilityOrFrequencyOpenStructureBeforeFlooding = value; } } Index: Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Data/Properties/Resources.Designer.cs =================================================================== diff -u -ra964168b91bc9c287adacc368480575f0bcf8cd9 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Data/Properties/Resources.Designer.cs (.../Resources.Designer.cs) (revision a964168b91bc9c287adacc368480575f0bcf8cd9) +++ Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Data/Properties/Resources.Designer.cs (.../Resources.Designer.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -1,25 +1,4 @@ -// Copyright (C) Stichting Deltares 2016. All rights reserved. -// -// This file is part of Ringtoets. -// -// Ringtoets 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.18444 @@ -109,6 +88,16 @@ } /// + /// Looks up a localized string similar to De waarde moet groter of gelijk aan 0 zijn.. + /// + public static string ClosingStructuresInput_ProbabilityOrFrequencyOpenStructureBeforeFlooding_Value_must_be_greater_or_equal_to_zero { + get { + return ResourceManager.GetString("ClosingStructuresInput_ProbabilityOrFrequencyOpenStructureBeforeFlooding_Value_mu" + + "st_be_greater_or_equal_to_zero", resourceCulture); + } + } + + /// /// Looks up a localized string similar to De waarde voor 'N2A' moet in het bereik [0, 40] liggen.. /// public static string N2A_Value_should_be_in_interval_0_40 { Index: Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Data/Properties/Resources.resx =================================================================== diff -u -ra964168b91bc9c287adacc368480575f0bcf8cd9 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Data/Properties/Resources.resx (.../Resources.resx) (revision a964168b91bc9c287adacc368480575f0bcf8cd9) +++ Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Data/Properties/Resources.resx (.../Resources.resx) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -129,4 +129,7 @@ De waarde voor 'N2A' moet in het bereik [0, 40] liggen. + + De waarde moet groter of gelijk aan 0 zijn. + \ No newline at end of file Index: Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Forms/PropertyClasses/ClosingStructureProperties.cs =================================================================== diff -u -ra16989b635b3770eb1bbf10c47e41eef796ce2fa -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Forms/PropertyClasses/ClosingStructureProperties.cs (.../ClosingStructureProperties.cs) (revision a16989b635b3770eb1bbf10c47e41eef796ce2fa) +++ Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Forms/PropertyClasses/ClosingStructureProperties.cs (.../ClosingStructureProperties.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -271,7 +271,7 @@ { get { - return ProbabilityFormattingHelper.Format(data.ProbabilityOpenStructureBeforeFlooding); + return ProbabilityFormattingHelper.Format(data.ProbabilityOrFrequencyOpenStructureBeforeFlooding); } } Index: Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Forms/PropertyClasses/ClosingStructuresInputContextProperties.cs =================================================================== diff -u -rb66269d1c3435557b993a5daa333612017f6ccfd -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Forms/PropertyClasses/ClosingStructuresInputContextProperties.cs (.../ClosingStructuresInputContextProperties.cs) (revision b66269d1c3435557b993a5daa333612017f6ccfd) +++ Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Forms/PropertyClasses/ClosingStructuresInputContextProperties.cs (.../ClosingStructuresInputContextProperties.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -373,11 +373,11 @@ { get { - return ProbabilityFormattingHelper.Format(data.WrappedData.ProbabilityOpenStructureBeforeFlooding); + return ProbabilityFormattingHelper.Format(data.WrappedData.ProbabilityOrFrequencyOpenStructureBeforeFlooding); } set { - SetProbabilityValue(value, data.WrappedData, (wrappedData, parsedValue) => wrappedData.ProbabilityOpenStructureBeforeFlooding = parsedValue); + SetProbabilityValue(value, data.WrappedData, (wrappedData, parsedValue) => wrappedData.ProbabilityOrFrequencyOpenStructureBeforeFlooding = parsedValue); } } Index: Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.IO/ClosingStructuresImporter.cs =================================================================== diff -u -r7e24cbef3a5a475fef4442be00ced9e5305e0b24 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.IO/ClosingStructuresImporter.cs (.../ClosingStructuresImporter.cs) (revision 7e24cbef3a5a475fef4442be00ced9e5305e0b24) +++ Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.IO/ClosingStructuresImporter.cs (.../ClosingStructuresImporter.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -147,7 +147,7 @@ Mean = (RoundedDouble) rowData[StructureFilesKeywords.ClosingStructureParameterKeyword10].NumericalValue, StandardDeviation = GetStandardDeviation(rowData[StructureFilesKeywords.ClosingStructureParameterKeyword10], structureName) }, - ProbabilityOpenStructureBeforeFlooding = rowData[StructureFilesKeywords.ClosingStructureParameterKeyword11].NumericalValue, + ProbabilityOrFrequencyOpenStructureBeforeFlooding = rowData[StructureFilesKeywords.ClosingStructureParameterKeyword11].NumericalValue, FailureProbabilityOpenStructure = rowData[StructureFilesKeywords.ClosingStructureParameterKeyword12].NumericalValue, IdenticalApertures = (int) rowData[StructureFilesKeywords.ClosingStructureParameterKeyword13].NumericalValue, FailureProbabilityReparation = rowData[StructureFilesKeywords.ClosingStructureParameterKeyword14].NumericalValue, Index: Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Service/ClosingStructuresCalculationService.cs =================================================================== diff -u -r533cc8038f03f3acb30f4db787a3d583f93f7008 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Service/ClosingStructuresCalculationService.cs (.../ClosingStructuresCalculationService.cs) (revision 533cc8038f03f3acb30f4db787a3d583f93f7008) +++ Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Service/ClosingStructuresCalculationService.cs (.../ClosingStructuresCalculationService.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -223,7 +223,7 @@ calculation.InputParameters.CriticalOvertoppingDischarge.Mean, calculation.InputParameters.CriticalOvertoppingDischarge.CoefficientOfVariation, calculation.InputParameters.FailureProbabilityStructureWithErosion, calculation.InputParameters.StormDuration.Mean, calculation.InputParameters.StormDuration.CoefficientOfVariation, - calculation.InputParameters.ProbabilityOpenStructureBeforeFlooding, + calculation.InputParameters.ProbabilityOrFrequencyOpenStructureBeforeFlooding, generalInput.ModelFactorOvertoppingFlow.Mean, generalInput.ModelFactorOvertoppingFlow.StandardDeviation, calculation.InputParameters.StructureNormalOrientation, calculation.InputParameters.ModelFactorSuperCriticalFlow.Mean, calculation.InputParameters.ModelFactorSuperCriticalFlow.StandardDeviation, @@ -260,7 +260,7 @@ calculation.InputParameters.CriticalOvertoppingDischarge.Mean, calculation.InputParameters.CriticalOvertoppingDischarge.CoefficientOfVariation, calculation.InputParameters.FailureProbabilityStructureWithErosion, calculation.InputParameters.StormDuration.Mean, calculation.InputParameters.StormDuration.CoefficientOfVariation, - calculation.InputParameters.ProbabilityOpenStructureBeforeFlooding, + calculation.InputParameters.ProbabilityOrFrequencyOpenStructureBeforeFlooding, calculation.InputParameters.ModelFactorSuperCriticalFlow.Mean, calculation.InputParameters.ModelFactorSuperCriticalFlow.StandardDeviation, generalInput.ModelFactorSubCriticalFlow.Mean, generalInput.ModelFactorSubCriticalFlow.CoefficientOfVariation, calculation.InputParameters.ThresholdHeightOpenWeir.Mean, calculation.InputParameters.ThresholdHeightOpenWeir.StandardDeviation, @@ -296,7 +296,7 @@ calculation.InputParameters.CriticalOvertoppingDischarge.Mean, calculation.InputParameters.CriticalOvertoppingDischarge.CoefficientOfVariation, calculation.InputParameters.FailureProbabilityStructureWithErosion, calculation.InputParameters.StormDuration.Mean, calculation.InputParameters.StormDuration.CoefficientOfVariation, - calculation.InputParameters.ProbabilityOpenStructureBeforeFlooding, + calculation.InputParameters.ProbabilityOrFrequencyOpenStructureBeforeFlooding, calculation.InputParameters.DrainCoefficient.Mean, calculation.InputParameters.DrainCoefficient.StandardDeviation, calculation.InputParameters.AreaFlowApertures.Mean, calculation.InputParameters.AreaFlowApertures.StandardDeviation, calculation.InputParameters.InsideWaterLevel.Mean, calculation.InputParameters.InsideWaterLevel.StandardDeviation); Index: Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Data.Test/ClosingStructureTest.cs =================================================================== diff -u -r2698972311ca90c3af1171c554c4dec237e34111 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Data.Test/ClosingStructureTest.cs (.../ClosingStructureTest.cs) (revision 2698972311ca90c3af1171c554c4dec237e34111) +++ Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Data.Test/ClosingStructureTest.cs (.../ClosingStructureTest.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -90,7 +90,7 @@ Mean = (RoundedDouble) 111.222, StandardDeviation = (RoundedDouble) 0.111 }, - ProbabilityOpenStructureBeforeFlooding = 321.987, + ProbabilityOrFrequencyOpenStructureBeforeFlooding = 321.987, FailureProbabilityOpenStructure = 654.321, IdenticalApertures = 42, FailureProbabilityReparation = 987.654, @@ -161,7 +161,7 @@ Assert.AreEqual(2, flowWidthAtBottomProtection.StandardDeviation.NumberOfDecimalPlaces); Assert.AreEqual(0.11, flowWidthAtBottomProtection.StandardDeviation, flowWidthAtBottomProtection.StandardDeviation.GetAccuracy()); - Assert.AreEqual(321.987, structure.ProbabilityOpenStructureBeforeFlooding); + Assert.AreEqual(321.987, structure.ProbabilityOrFrequencyOpenStructureBeforeFlooding); Assert.AreEqual(654.321, structure.FailureProbabilityOpenStructure); Assert.AreEqual(42, structure.IdenticalApertures); Assert.AreEqual(987.654, structure.FailureProbabilityReparation); Index: Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Data.Test/ClosingStructuresInputTest.cs =================================================================== diff -u -r7a6c07ce4fcb7887319744836e0b513709187445 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Data.Test/ClosingStructuresInputTest.cs (.../ClosingStructuresInputTest.cs) (revision 7a6c07ce4fcb7887319744836e0b513709187445) +++ Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Data.Test/ClosingStructuresInputTest.cs (.../ClosingStructuresInputTest.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -87,7 +87,7 @@ DistributionAssert.AreEqual(areaFlowApertures, input.AreaFlowApertures); DistributionAssert.AreEqual(levelCrestStructureNotClosing, input.LevelCrestStructureNotClosing); - Assert.AreEqual(1.0, input.ProbabilityOpenStructureBeforeFlooding); + Assert.AreEqual(1.0, input.ProbabilityOrFrequencyOpenStructureBeforeFlooding); Assert.AreEqual(0, input.IdenticalApertures); } @@ -379,19 +379,19 @@ } [Test] - [TestCase(-1.1)] - [TestCase(2)] + [TestCase(-1e-6)] + [TestCase(-23456)] [TestCase(double.NaN)] public void ProbabilityOpenStructureBeforeFlooding_InvalidValues_ThrowsArgumentOutOfRangeException(double probability) { // Setup var input = new ClosingStructuresInput(); // Call - TestDelegate call = () => input.ProbabilityOpenStructureBeforeFlooding = probability; + TestDelegate call = () => input.ProbabilityOrFrequencyOpenStructureBeforeFlooding = probability; // Assert - TestHelper.AssertThrowsArgumentExceptionAndTestMessage(call, "De waarde voor de faalkans moet in het bereik [0, 1] liggen."); + TestHelper.AssertThrowsArgumentExceptionAndTestMessage(call, "De waarde moet groter of gelijk aan 0 zijn."); } [Test] @@ -404,10 +404,10 @@ var input = new ClosingStructuresInput(); // Call - input.ProbabilityOpenStructureBeforeFlooding = probability; + input.ProbabilityOrFrequencyOpenStructureBeforeFlooding = probability; // Assert - Assert.AreEqual(probability, input.ProbabilityOpenStructureBeforeFlooding); + Assert.AreEqual(probability, input.ProbabilityOrFrequencyOpenStructureBeforeFlooding); } #endregion @@ -434,7 +434,7 @@ Assert.AreEqual(defaultInput.FailureProbabilityReparation, input.FailureProbabilityReparation); Assert.AreEqual(defaultInput.IdenticalApertures, input.IdenticalApertures); DistributionAssert.AreEqual(defaultInput.InsideWaterLevel, input.InsideWaterLevel); - Assert.AreEqual(defaultInput.ProbabilityOpenStructureBeforeFlooding, input.ProbabilityOpenStructureBeforeFlooding); + Assert.AreEqual(defaultInput.ProbabilityOrFrequencyOpenStructureBeforeFlooding, input.ProbabilityOrFrequencyOpenStructureBeforeFlooding); DistributionAssert.AreEqual(defaultInput.ThresholdHeightOpenWeir, input.ThresholdHeightOpenWeir); } else @@ -453,7 +453,7 @@ Assert.AreEqual(expectedClosingStructure.FailureProbabilityReparation, input.FailureProbabilityReparation); Assert.AreEqual(expectedClosingStructure.IdenticalApertures, input.IdenticalApertures); DistributionAssert.AreEqual(expectedClosingStructure.InsideWaterLevel, input.InsideWaterLevel); - Assert.AreEqual(expectedClosingStructure.ProbabilityOpenStructureBeforeFlooding, input.ProbabilityOpenStructureBeforeFlooding); + Assert.AreEqual(expectedClosingStructure.ProbabilityOrFrequencyOpenStructureBeforeFlooding, input.ProbabilityOrFrequencyOpenStructureBeforeFlooding); DistributionAssert.AreEqual(expectedClosingStructure.ThresholdHeightOpenWeir, input.ThresholdHeightOpenWeir); } } Index: Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Data.TestUtil.Test/TestClosingStructureCalculationTest.cs =================================================================== diff -u -rb4e3629ea2130359117dd403af8db3c8ae0c680b -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Data.TestUtil.Test/TestClosingStructureCalculationTest.cs (.../TestClosingStructureCalculationTest.cs) (revision b4e3629ea2130359117dd403af8db3c8ae0c680b) +++ Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Data.TestUtil.Test/TestClosingStructureCalculationTest.cs (.../TestClosingStructureCalculationTest.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -57,7 +57,7 @@ DistributionAssert.AreEqual(referenceStructure.AreaFlowApertures, calculation.InputParameters.AreaFlowApertures); DistributionAssert.AreEqual(referenceStructure.CriticalOvertoppingDischarge, calculation.InputParameters.CriticalOvertoppingDischarge); DistributionAssert.AreEqual(referenceStructure.FlowWidthAtBottomProtection, calculation.InputParameters.FlowWidthAtBottomProtection); - Assert.AreEqual(referenceStructure.ProbabilityOpenStructureBeforeFlooding, calculation.InputParameters.ProbabilityOpenStructureBeforeFlooding); + Assert.AreEqual(referenceStructure.ProbabilityOrFrequencyOpenStructureBeforeFlooding, calculation.InputParameters.ProbabilityOrFrequencyOpenStructureBeforeFlooding); Assert.AreEqual(referenceStructure.FailureProbabilityOpenStructure, calculation.InputParameters.FailureProbabilityOpenStructure); Assert.AreEqual(referenceStructure.IdenticalApertures, calculation.InputParameters.IdenticalApertures); Assert.AreEqual(referenceStructure.FailureProbabilityOpenStructure, calculation.InputParameters.FailureProbabilityOpenStructure); Index: Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Data.TestUtil.Test/TestClosingStructureTest.cs =================================================================== diff -u -r3f40e34c76b06d66a6426c7e07fb3a101b4952cb -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Data.TestUtil.Test/TestClosingStructureTest.cs (.../TestClosingStructureTest.cs) (revision 3f40e34c76b06d66a6426c7e07fb3a101b4952cb) +++ Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Data.TestUtil.Test/TestClosingStructureTest.cs (.../TestClosingStructureTest.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -121,7 +121,7 @@ Assert.AreEqual(25.0, structure.FlowWidthAtBottomProtection.Mean.Value); Assert.AreEqual(0.05, structure.FlowWidthAtBottomProtection.StandardDeviation.Value); - Assert.AreEqual(1.0, structure.ProbabilityOpenStructureBeforeFlooding); + Assert.AreEqual(1.0, structure.ProbabilityOrFrequencyOpenStructureBeforeFlooding); Assert.AreEqual(0.1, structure.FailureProbabilityOpenStructure); Assert.AreEqual(4, structure.IdenticalApertures); Assert.AreEqual(1.0, structure.FailureProbabilityReparation); Index: Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Data.TestUtil/TestClosingStructure.cs =================================================================== diff -u -r7ae9100ff4e61169edcefaeb01b72d492431742f -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Data.TestUtil/TestClosingStructure.cs (.../TestClosingStructure.cs) (revision 7ae9100ff4e61169edcefaeb01b72d492431742f) +++ Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Data.TestUtil/TestClosingStructure.cs (.../TestClosingStructure.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -89,7 +89,7 @@ Mean = (RoundedDouble) 25.0, StandardDeviation = (RoundedDouble) 0.05 }, - ProbabilityOpenStructureBeforeFlooding = 1.0, + ProbabilityOrFrequencyOpenStructureBeforeFlooding = 1.0, FailureProbabilityOpenStructure = 0.1, IdenticalApertures = 4, FailureProbabilityReparation = 1.0, Index: Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Forms.Test/PropertyClasses/ClosingStructurePropertiesTest.cs =================================================================== diff -u -r5c5df51bc14a7e25692abf1db5a7476e5036b13f -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Forms.Test/PropertyClasses/ClosingStructurePropertiesTest.cs (.../ClosingStructurePropertiesTest.cs) (revision 5c5df51bc14a7e25692abf1db5a7476e5036b13f) +++ Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Forms.Test/PropertyClasses/ClosingStructurePropertiesTest.cs (.../ClosingStructurePropertiesTest.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -127,7 +127,7 @@ Assert.IsTrue(properties.CriticalOvertoppingDischarge.DynamicReadOnlyValidationMethod("Mean")); Assert.IsTrue(properties.CriticalOvertoppingDischarge.DynamicReadOnlyValidationMethod("CoefficientOfVariation")); - Assert.AreEqual(ProbabilityFormattingHelper.Format(structure.ProbabilityOpenStructureBeforeFlooding), properties.ProbabilityOpenStructureBeforeFlooding); + Assert.AreEqual(ProbabilityFormattingHelper.Format(structure.ProbabilityOrFrequencyOpenStructureBeforeFlooding), properties.ProbabilityOpenStructureBeforeFlooding); Assert.AreEqual(ProbabilityFormattingHelper.Format(structure.FailureProbabilityOpenStructure), properties.FailureProbabilityOpenStructure); Assert.AreEqual(ProbabilityFormattingHelper.Format(structure.FailureProbabilityReparation), properties.FailureProbabilityReparation); } Index: Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Forms.Test/PropertyClasses/ClosingStructuresInputContextPropertiesTest.cs =================================================================== diff -u -r4af9b44a7b9bea4035396ef522fe83c4cdd6f398 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Forms.Test/PropertyClasses/ClosingStructuresInputContextPropertiesTest.cs (.../ClosingStructuresInputContextPropertiesTest.cs) (revision 4af9b44a7b9bea4035396ef522fe83c4cdd6f398) +++ Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Forms.Test/PropertyClasses/ClosingStructuresInputContextPropertiesTest.cs (.../ClosingStructuresInputContextPropertiesTest.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -89,7 +89,7 @@ // Assert ClosingStructuresInput input = calculation.InputParameters; - var expectedProbabilityOpenStructureBeforeFlooding = ProbabilityFormattingHelper.Format(input.ProbabilityOpenStructureBeforeFlooding); + var expectedProbabilityOpenStructureBeforeFlooding = ProbabilityFormattingHelper.Format(input.ProbabilityOrFrequencyOpenStructureBeforeFlooding); var expectedFailureProbabilityOpenStructure = ProbabilityFormattingHelper.Format(input.FailureProbabilityOpenStructure); var expectedFailureProbabilityReparation = ProbabilityFormattingHelper.Format(input.FailureProbabilityReparation); Index: Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Service.Test/ClosingStructuresCalculationServiceTest.cs =================================================================== diff -u -re182f6f394aa75e739467a77e7bcacd9a8b25429 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Service.Test/ClosingStructuresCalculationServiceTest.cs (.../ClosingStructuresCalculationServiceTest.cs) (revision e182f6f394aa75e739467a77e7bcacd9a8b25429) +++ Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Service.Test/ClosingStructuresCalculationServiceTest.cs (.../ClosingStructuresCalculationServiceTest.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -579,7 +579,7 @@ input.CriticalOvertoppingDischarge.Mean, input.CriticalOvertoppingDischarge.CoefficientOfVariation, input.FailureProbabilityStructureWithErosion, input.StormDuration.Mean, input.StormDuration.CoefficientOfVariation, - input.ProbabilityOpenStructureBeforeFlooding, + input.ProbabilityOrFrequencyOpenStructureBeforeFlooding, generalInput.ModelFactorOvertoppingFlow.Mean, generalInput.ModelFactorOvertoppingFlow.StandardDeviation, input.StructureNormalOrientation, input.ModelFactorSuperCriticalFlow.Mean, input.ModelFactorSuperCriticalFlow.StandardDeviation, @@ -665,7 +665,7 @@ input.CriticalOvertoppingDischarge.Mean, input.CriticalOvertoppingDischarge.CoefficientOfVariation, input.FailureProbabilityStructureWithErosion, input.StormDuration.Mean, input.StormDuration.CoefficientOfVariation, - input.ProbabilityOpenStructureBeforeFlooding, + input.ProbabilityOrFrequencyOpenStructureBeforeFlooding, input.ModelFactorSuperCriticalFlow.Mean, input.ModelFactorSuperCriticalFlow.StandardDeviation, generalInput.ModelFactorSubCriticalFlow.Mean, generalInput.ModelFactorSubCriticalFlow.CoefficientOfVariation, input.ThresholdHeightOpenWeir.Mean, input.ThresholdHeightOpenWeir.StandardDeviation, @@ -750,7 +750,7 @@ input.CriticalOvertoppingDischarge.Mean, input.CriticalOvertoppingDischarge.CoefficientOfVariation, input.FailureProbabilityStructureWithErosion, input.StormDuration.Mean, input.StormDuration.CoefficientOfVariation, - input.ProbabilityOpenStructureBeforeFlooding, + input.ProbabilityOrFrequencyOpenStructureBeforeFlooding, input.DrainCoefficient.Mean, input.DrainCoefficient.StandardDeviation, input.AreaFlowApertures.Mean, input.AreaFlowApertures.StandardDeviation, input.InsideWaterLevel.Mean, input.InsideWaterLevel.StandardDeviation); Index: Ringtoets/Common/src/Ringtoets.Common.IO/Properties/Resources.Designer.cs =================================================================== diff -u -r16619bc4d9f84a35b603217d2eaddfe9092783a7 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/Common/src/Ringtoets.Common.IO/Properties/Resources.Designer.cs (.../Resources.Designer.cs) (revision 16619bc4d9f84a35b603217d2eaddfe9092783a7) +++ Ringtoets/Common/src/Ringtoets.Common.IO/Properties/Resources.Designer.cs (.../Resources.Designer.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -1304,6 +1304,16 @@ } /// + /// Looks up a localized string similar to De waarde voor parameter '{0}' op regel {1}, kolom '{2}', moet getal zijn groter dan 0.. + /// + public static string StructuresParameterRowsValidator_ValidatePositiveDoubleParameter_ParameterId_0_Line_1_ColumnName_2_must_be_greater_than_zero { + get { + return ResourceManager.GetString("StructuresParameterRowsValidator_ValidatePositiveDoubleParameter_ParameterId_0_Li" + + "ne_1_ColumnName_2_must_be_greater_than_zero", resourceCulture); + } + } + + /// /// Looks up a localized string similar to Het kunstwerk heeft geen geldige waarde voor attribuut '{0}'.. /// public static string StructuresReader_GetNextStructure_Invalid_KWKIDENT { Index: Ringtoets/Common/src/Ringtoets.Common.IO/Properties/Resources.resx =================================================================== diff -u -r16619bc4d9f84a35b603217d2eaddfe9092783a7 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/Common/src/Ringtoets.Common.IO/Properties/Resources.resx (.../Resources.resx) (revision 16619bc4d9f84a35b603217d2eaddfe9092783a7) +++ Ringtoets/Common/src/Ringtoets.Common.IO/Properties/Resources.resx (.../Resources.resx) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -495,4 +495,7 @@ ID + + De waarde voor parameter '{0}' op regel {1}, kolom '{2}', moet een getal zijn groter dan 0. + \ No newline at end of file Index: Ringtoets/Common/src/Ringtoets.Common.IO/Structures/StructureFilesKeywords.cs =================================================================== diff -u -r7d6e4c28a40fb056c182d0691dda2b2e88aeebfd -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/Common/src/Ringtoets.Common.IO/Structures/StructureFilesKeywords.cs (.../StructureFilesKeywords.cs) (revision 7d6e4c28a40fb056c182d0691dda2b2e88aeebfd) +++ Ringtoets/Common/src/Ringtoets.Common.IO/Structures/StructureFilesKeywords.cs (.../StructureFilesKeywords.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -141,7 +141,7 @@ public const string ClosingStructureParameterKeyword10 = "KW_BETSLUIT10"; /// - /// The probability of the closing structure being open before flooding. + /// The probability or frequency of the closing structure being open before flooding. /// [1/year] /// public const string ClosingStructureParameterKeyword11 = "KW_BETSLUIT11"; Index: Ringtoets/Common/src/Ringtoets.Common.IO/Structures/StructuresParameterRowsValidator.cs =================================================================== diff -u -r56ec7114c4c96eeee4a1bb16d0ecac2bb10a49b8 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/Common/src/Ringtoets.Common.IO/Structures/StructuresParameterRowsValidator.cs (.../StructuresParameterRowsValidator.cs) (revision 56ec7114c4c96eeee4a1bb16d0ecac2bb10a49b8) +++ Ringtoets/Common/src/Ringtoets.Common.IO/Structures/StructuresParameterRowsValidator.cs (.../StructuresParameterRowsValidator.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -115,7 +115,7 @@ StructureFilesKeywords.ClosingStructureParameterKeyword10, LogNormalDistributionRule }, { - StructureFilesKeywords.ClosingStructureParameterKeyword11, ProbabilityRule + StructureFilesKeywords.ClosingStructureParameterKeyword11, PositiveDoubleRule }, { StructureFilesKeywords.ClosingStructureParameterKeyword12, ProbabilityRule @@ -316,6 +316,20 @@ return messages; } + private static List ValidateGreaterThanZeroDoubleParameter(StructuresParameterRow row, string columnName) + { + var messages = new List(); + + double value = GetValueFromRowForColumn(row, columnName); + if (double.IsNaN(value) || double.IsInfinity(value) || value <= 0) + { + messages.Add(string.Format(Resources.StructuresParameterRowsValidator_ValidatePositiveDoubleParameter_ParameterId_0_Line_1_ColumnName_2_must_be_greater_than_zero, + row.ParameterId, row.LineNumber, columnName.FirstToUpper())); + } + + return messages; + } + private static double GetValueFromRowForColumn(StructuresParameterRow row, string columnName) { switch (columnName) @@ -370,7 +384,7 @@ double mean = row.NumericalValue; var numericalValueColumn1 = StructureFilesKeywords.NumericalValueColumnName; messages.AddRange(meanMustBeGreaterThanZero ? - ValidatePositiveDoubleParameter(row, numericalValueColumn1) : + ValidateGreaterThanZeroDoubleParameter(row, numericalValueColumn1) : ValidateDoubleParameter(row, numericalValueColumn1)); VarianceType type = row.VarianceType; Index: Ringtoets/Common/test/Ringtoets.Common.IO.Test/Structures/StructuresParameterRowsValidatorTest.cs =================================================================== diff -u -r723c48084f30ec6a930a9ef16cf1a657e9eeec65 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/Common/test/Ringtoets.Common.IO.Test/Structures/StructuresParameterRowsValidatorTest.cs (.../StructuresParameterRowsValidatorTest.cs) (revision 723c48084f30ec6a930a9ef16cf1a657e9eeec65) +++ Ringtoets/Common/test/Ringtoets.Common.IO.Test/Structures/StructuresParameterRowsValidatorTest.cs (.../StructuresParameterRowsValidatorTest.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -133,7 +133,7 @@ new StructuresParameterRow { ParameterId = StructureFilesKeywords.HeightStructureParameterKeyword8, - NumericalValue = 0, + NumericalValue = 1e-6, VarianceValue = 10.0, VarianceType = VarianceType.CoefficientOfVariation, LineNumber = 8 @@ -151,10 +151,10 @@ "De waarde voor parameter 'KW_HOOGTE2' op regel 2, kolom 'Numeriekewaarde', is geen getal.", "De waarde voor parameter 'KW_HOOGTE2' op regel 2, kolom 'Boolean', moet '0' (variatiecoëfficiënt) of '1' (standaardafwijking) zijn.", "De waarde voor parameter 'KW_HOOGTE2' op regel 2, kolom 'Standaardafwijking.variatie', moet een positief getal zijn.", - "De waarde voor parameter 'KW_HOOGTE3' op regel 3, kolom 'Numeriekewaarde', moet een positief getal zijn.", + "De waarde voor parameter 'KW_HOOGTE3' op regel 3, kolom 'Numeriekewaarde', moet een getal zijn groter dan 0.", "De waarde voor parameter 'KW_HOOGTE3' op regel 3, kolom 'Boolean', moet '0' (variatiecoëfficiënt) of '1' (standaardafwijking) zijn.", "De waarde voor parameter 'KW_HOOGTE3' op regel 3, kolom 'Standaardafwijking.variatie', moet een positief getal zijn.", - "De waarde voor parameter 'KW_HOOGTE4' op regel 4, kolom 'Numeriekewaarde', moet een positief getal zijn.", + "De waarde voor parameter 'KW_HOOGTE4' op regel 4, kolom 'Numeriekewaarde', moet een getal zijn groter dan 0.", "De waarde voor parameter 'KW_HOOGTE4' op regel 4, kolom 'Boolean', moet '0' (variatiecoëfficiënt) of '1' (standaardafwijking) zijn.", "De waarde voor parameter 'KW_HOOGTE4' op regel 4, kolom 'Standaardafwijking.variatie', moet een positief getal zijn.", "De waarde voor parameter 'KW_HOOGTE5' op regel 5, kolom 'Numeriekewaarde', is geen getal.", @@ -418,24 +418,24 @@ List expectedErrorMessages = new List { "De waarde voor parameter 'KW_BETSLUIT1' op regel 1, kolom 'Numeriekewaarde', is te dicht op 0 waardoor een betrouwbare conversie tussen standaardafwijking en variatiecoëfficiënt niet mogelijk is.", - "De waarde voor parameter 'KW_BETSLUIT2' op regel 2, kolom 'Numeriekewaarde', moet een positief getal zijn.", + "De waarde voor parameter 'KW_BETSLUIT2' op regel 2, kolom 'Numeriekewaarde', moet een getal zijn groter dan 0.", "De waarde voor parameter 'KW_BETSLUIT3' op regel 3, kolom 'Numeriekewaarde', moet in het bereik [0, 360] liggen.", "De waarde voor parameter 'KW_BETSLUIT5' op regel 5, kolom 'Numeriekewaarde', is geen getal.", "De waarde voor parameter 'KW_BETSLUIT5' op regel 5, kolom 'Boolean', moet '0' (variatiecoëfficiënt) of '1' (standaardafwijking) zijn.", "De waarde voor parameter 'KW_BETSLUIT6' op regel 6, kolom 'Numeriekewaarde', is geen getal.", "De waarde voor parameter 'KW_BETSLUIT6' op regel 6, kolom 'Boolean', moet '0' (variatiecoëfficiënt) of '1' (standaardafwijking) zijn.", "De waarde voor parameter 'KW_BETSLUIT7' op regel 7, kolom 'Numeriekewaarde', is geen getal.", "De waarde voor parameter 'KW_BETSLUIT7' op regel 7, kolom 'Boolean', moet '0' (variatiecoëfficiënt) of '1' (standaardafwijking) zijn.", - "De waarde voor parameter 'KW_BETSLUIT8' op regel 8, kolom 'Numeriekewaarde', moet een positief getal zijn.", + "De waarde voor parameter 'KW_BETSLUIT8' op regel 8, kolom 'Numeriekewaarde', moet een getal zijn groter dan 0.", "De waarde voor parameter 'KW_BETSLUIT8' op regel 8, kolom 'Boolean', moet '0' (variatiecoëfficiënt) of '1' (standaardafwijking) zijn.", "De waarde voor parameter 'KW_BETSLUIT8' op regel 8, kolom 'Standaardafwijking.variatie', moet een positief getal zijn.", - "De waarde voor parameter 'KW_BETSLUIT9' op regel 9, kolom 'Numeriekewaarde', moet een positief getal zijn.", + "De waarde voor parameter 'KW_BETSLUIT9' op regel 9, kolom 'Numeriekewaarde', moet een getal zijn groter dan 0.", "De waarde voor parameter 'KW_BETSLUIT9' op regel 9, kolom 'Boolean', moet '0' (variatiecoëfficiënt) of '1' (standaardafwijking) zijn.", "De waarde voor parameter 'KW_BETSLUIT9' op regel 9, kolom 'Standaardafwijking.variatie', moet een positief getal zijn.", - "De waarde voor parameter 'KW_BETSLUIT10' op regel 10, kolom 'Numeriekewaarde', moet een positief getal zijn.", + "De waarde voor parameter 'KW_BETSLUIT10' op regel 10, kolom 'Numeriekewaarde', moet een getal zijn groter dan 0.", "De waarde voor parameter 'KW_BETSLUIT10' op regel 10, kolom 'Boolean', moet '0' (variatiecoëfficiënt) of '1' (standaardafwijking) zijn.", "De waarde voor parameter 'KW_BETSLUIT10' op regel 10, kolom 'Standaardafwijking.variatie', moet een positief getal zijn.", - "De waarde voor parameter 'KW_BETSLUIT11' op regel 11, kolom 'Numeriekewaarde', moet in het bereik [0, 1] liggen.", + "De waarde voor parameter 'KW_BETSLUIT11' op regel 11, kolom 'Numeriekewaarde', moet een positief getal zijn.", "De waarde voor parameter 'KW_BETSLUIT12' op regel 12, kolom 'Numeriekewaarde', moet in het bereik [0, 1] liggen.", "De waarde voor parameter 'KW_BETSLUIT13' op regel 13, kolom 'Numeriekewaarde', moet een positief geheel getal zijn.", "De waarde voor parameter 'KW_BETSLUIT14' op regel 14, kolom 'Numeriekewaarde', moet in het bereik [0, 1] liggen.", @@ -445,6 +445,130 @@ } [Test] + public void ValidateClosingStructuresParameters_ParametersAllValid_ValidIsTrueAndNoErrorMessages() + { + // Setup + List structureParameterRows = new List + { + new StructuresParameterRow + { + ParameterId = "KW_BETSLUIT1", + NumericalValue = 3, + VarianceValue = 1.0, + VarianceType = VarianceType.StandardDeviation, + LineNumber = 1 + }, + new StructuresParameterRow + { + ParameterId = "KW_BETSLUIT2", + NumericalValue = 1, + VarianceValue = 10.0, + VarianceType = VarianceType.StandardDeviation, + LineNumber = 2 + }, + new StructuresParameterRow + { + ParameterId = "KW_BETSLUIT3", + NumericalValue = 123, + LineNumber = 3 + }, + new StructuresParameterRow + { + ParameterId = "KW_BETSLUIT4", + NumericalValue = 0, + VarianceValue = 10.0, + VarianceType = VarianceType.CoefficientOfVariation, + LineNumber = 4 + }, + new StructuresParameterRow + { + ParameterId = "KW_BETSLUIT5", + NumericalValue = 1, + VarianceValue = 10.0, + VarianceType = VarianceType.StandardDeviation, + LineNumber = 5 + }, + new StructuresParameterRow + { + ParameterId = "KW_BETSLUIT6", + NumericalValue = 9, + VarianceValue = 10.0, + VarianceType = VarianceType.CoefficientOfVariation, + LineNumber = 6 + }, + new StructuresParameterRow + { + ParameterId = "KW_BETSLUIT7", + NumericalValue = 1, + VarianceValue = 10.0, + VarianceType = VarianceType.StandardDeviation, + LineNumber = 7 + }, + new StructuresParameterRow + { + ParameterId = "KW_BETSLUIT8", + NumericalValue = 1, + VarianceValue = 2, + VarianceType = VarianceType.CoefficientOfVariation, + LineNumber = 8 + }, + new StructuresParameterRow + { + ParameterId = "KW_BETSLUIT9", + NumericalValue = 2, + VarianceValue = 3, + VarianceType = VarianceType.StandardDeviation, + LineNumber = 9 + }, + new StructuresParameterRow + { + ParameterId = "KW_BETSLUIT10", + NumericalValue = 9, + VarianceValue = 3, + VarianceType = VarianceType.CoefficientOfVariation, + LineNumber = 10 + }, + new StructuresParameterRow + { + ParameterId = "KW_BETSLUIT11", + NumericalValue = 123, + LineNumber = 11 + }, + new StructuresParameterRow + { + ParameterId = "KW_BETSLUIT12", + NumericalValue = 0.6, + LineNumber = 12 + }, + new StructuresParameterRow + { + ParameterId = "KW_BETSLUIT13", + NumericalValue = 14, + LineNumber = 13 + }, + new StructuresParameterRow + { + ParameterId = "KW_BETSLUIT14", + NumericalValue = 0.8, + LineNumber = 14 + }, + new StructuresParameterRow + { + ParameterId = "KW_BETSLUIT15", + AlphanumericValue = "verticalewand", + LineNumber = 15 + } + }; + + // Call + ValidationResult validationResult = StructuresParameterRowsValidator.ValidateClosingStructuresParameters(structureParameterRows); + + // Assert + Assert.IsTrue(validationResult.IsValid); + CollectionAssert.IsEmpty(validationResult.ErrorMessages); + } + + [Test] public void ValidateClosingStructuresParameters_VarianceValueConversionWithNegativeMean_NoErrorMessage() { // Setup @@ -842,15 +966,15 @@ { "De waarde voor parameter 'KW_STERSTAB1' op regel 1, kolom 'Numeriekewaarde', moet in het bereik [0, 360] liggen.", "De waarde voor parameter 'KW_STERSTAB2' op regel 2, kolom 'Numeriekewaarde', is te dicht op 0 waardoor een betrouwbare conversie tussen standaardafwijking en variatiecoëfficiënt niet mogelijk is.", - "De waarde voor parameter 'KW_STERSTAB3' op regel 3, kolom 'Numeriekewaarde', moet een positief getal zijn.", + "De waarde voor parameter 'KW_STERSTAB3' op regel 3, kolom 'Numeriekewaarde', moet een getal zijn groter dan 0.", "De waarde voor parameter 'KW_STERSTAB3' op regel 3, kolom 'Boolean', moet '0' (variatiecoëfficiënt) of '1' (standaardafwijking) zijn.", "De waarde voor parameter 'KW_STERSTAB3' op regel 3, kolom 'Standaardafwijking.variatie', moet een positief getal zijn.", "De waarde voor parameter 'KW_STERSTAB5' op regel 5, kolom 'Numeriekewaarde', is geen getal.", "De waarde voor parameter 'KW_STERSTAB5' op regel 5, kolom 'Boolean', moet '0' (variatiecoëfficiënt) of '1' (standaardafwijking) zijn.", "De waarde voor parameter 'KW_STERSTAB6' op regel 6, kolom 'Numeriekewaarde', is geen getal.", "De waarde voor parameter 'KW_STERSTAB6' op regel 6, kolom 'Boolean', moet '0' (variatiecoëfficiënt) of '1' (standaardafwijking) zijn.", "De waarde voor parameter 'KW_STERSTAB7' op regel 7, kolom 'Numeriekewaarde', is te dicht op 0 waardoor een betrouwbare conversie tussen standaardafwijking en variatiecoëfficiënt niet mogelijk is.", - "De waarde voor parameter 'KW_STERSTAB8' op regel 8, kolom 'Numeriekewaarde', moet een positief getal zijn.", + "De waarde voor parameter 'KW_STERSTAB8' op regel 8, kolom 'Numeriekewaarde', moet een getal zijn groter dan 0.", "De waarde voor parameter 'KW_STERSTAB8' op regel 8, kolom 'Boolean', moet '0' (variatiecoëfficiënt) of '1' (standaardafwijking) zijn.", "De waarde voor parameter 'KW_STERSTAB8' op regel 8, kolom 'Standaardafwijking.variatie', moet een positief getal zijn.", "De waarde voor parameter 'KW_STERSTAB9' op regel 9, kolom 'Numeriekewaarde', is te dicht op 0 waardoor een betrouwbare conversie tussen standaardafwijking en variatiecoëfficiënt niet mogelijk is.", @@ -871,7 +995,7 @@ "De waarde voor parameter 'KW_STERSTAB22' op regel 22, kolom 'Boolean', moet '0' (variatiecoëfficiënt) of '1' (standaardafwijking) zijn.", "De waarde voor parameter 'KW_STERSTAB23' op regel 23, kolom 'Numeriekewaarde', is te dicht op 0 waardoor een betrouwbare conversie tussen standaardafwijking en variatiecoëfficiënt niet mogelijk is.", "De waarde voor parameter 'KW_STERSTAB24' op regel 24, kolom 'Numeriekewaarde', is te dicht op 0 waardoor een betrouwbare conversie tussen standaardafwijking en variatiecoëfficiënt niet mogelijk is.", - "De waarde voor parameter 'KW_STERSTAB25' op regel 25, kolom 'Numeriekewaarde', moet een positief getal zijn.", + "De waarde voor parameter 'KW_STERSTAB25' op regel 25, kolom 'Numeriekewaarde', moet een getal zijn groter dan 0.", "De waarde voor parameter 'KW_STERSTAB25' op regel 25, kolom 'Boolean', moet '0' (variatiecoëfficiënt) of '1' (standaardafwijking) zijn.", "De waarde voor parameter 'KW_STERSTAB25' op regel 25, kolom 'Standaardafwijking.variatie', moet een positief getal zijn.", "De waarde voor parameter 'KW_STERSTAB26' op regel 26, kolom 'Alfanumeriekewaarde', moet een geldig kunstwerk type zijn." Index: Ringtoets/StabilityPointStructures/test/Ringtoets.StabilityPointStructures.IO.Test/StabilityPointStructuresImporterTest.cs =================================================================== diff -u -r2aa9661130f20e88c41dac921ffb780573dcf799 -rd641f7a03b05f5d7e48f9adeffabafdcb48e1c14 --- Ringtoets/StabilityPointStructures/test/Ringtoets.StabilityPointStructures.IO.Test/StabilityPointStructuresImporterTest.cs (.../StabilityPointStructuresImporterTest.cs) (revision 2aa9661130f20e88c41dac921ffb780573dcf799) +++ Ringtoets/StabilityPointStructures/test/Ringtoets.StabilityPointStructures.IO.Test/StabilityPointStructuresImporterTest.cs (.../StabilityPointStructuresImporterTest.cs) (revision d641f7a03b05f5d7e48f9adeffabafdcb48e1c14) @@ -256,7 +256,7 @@ new[] { "Parameter 'KW_STERSTAB9' komt meerdere keren voor.", - "De waarde voor parameter 'KW_STERSTAB10' op regel 37, kolom 'Numeriekewaarde', moet een positief getal zijn." + "De waarde voor parameter 'KW_STERSTAB10' op regel 37, kolom 'Numeriekewaarde', moet een getal zijn groter dan 0." }), CreateExpectedErrorMessage(csvFilePath, "Gemaal Leemans (93k3)", "KUNST2", expectedSubMessages), CreateExpectedErrorMessage(csvFilePath, "Gemaal Lely (93k4)", "KUNST3", expectedSubMessages),