Index: DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator.Tests/Deltares.DamPiping.BlighCalculator.Tests.csproj =================================================================== diff -u -r4360 -r4361 --- DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator.Tests/Deltares.DamPiping.BlighCalculator.Tests.csproj (.../Deltares.DamPiping.BlighCalculator.Tests.csproj) (revision 4360) +++ DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator.Tests/Deltares.DamPiping.BlighCalculator.Tests.csproj (.../Deltares.DamPiping.BlighCalculator.Tests.csproj) (revision 4361) @@ -1,5 +1,5 @@ - + net6.0 @@ -8,7 +8,7 @@ - + Index: DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator/Properties/Resources.resx =================================================================== diff -u -r878 -r4361 --- DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator/Properties/Resources.resx (.../Resources.resx) (revision 878) +++ DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator/Properties/Resources.resx (.../Resources.resx) (revision 4361) @@ -1,129 +1,134 @@  - - - - - - - + + + + - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, + PublicKeyToken=b77a5c561934e089 + + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, + PublicKeyToken=b77a5c561934e089 + + + Rc may not be less than 0. - + Parameter {0} is not a number (NaN). - + HRiver - HExit - (Rc*DTotal) may not be 0. \ No newline at end of file Index: DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator/Properties/AssemblyInfo.cs =================================================================== diff -u -r4360 -r4361 --- DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator/Properties/AssemblyInfo.cs (.../AssemblyInfo.cs) (revision 4360) +++ DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator/Properties/AssemblyInfo.cs (.../AssemblyInfo.cs) (revision 4361) @@ -1,8 +1,8 @@ -// Copyright (C) Stichting Deltares 2018. All rights reserved. -// -// This file is part of the Dam Piping Kernels. -// -// The Dam Macrostability Kernel is free software: you can redistribute it and/or modify +// Copyright (C) Stichting Deltares 2023. All rights reserved. +// +// This file is part of the Dam Piping Kernel. +// +// The Dam Piping Kernel is free software: you can redistribute it and/or modify // it under the terms of the GNU Affero General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. @@ -11,17 +11,17 @@ // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU Affero General Public License for more details. -// +// // You should have received a copy of the GNU Affero 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. -using System.Runtime.InteropServices; using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; [assembly: Guid("ca25d0bc-fac6-429b-9fcf-e57e357889b9")] -[assembly: InternalsVisibleTo("Deltares.DamPiping.BlighCalculatorTests")] +[assembly: InternalsVisibleTo("Deltares.DamPiping.BlighCalculatorTests")] \ No newline at end of file Index: DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator.Tests/PipingCalculatorBlighTests.cs =================================================================== diff -u -r4360 -r4361 --- DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator.Tests/PipingCalculatorBlighTests.cs (.../PipingCalculatorBlighTests.cs) (revision 4360) +++ DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator.Tests/PipingCalculatorBlighTests.cs (.../PipingCalculatorBlighTests.cs) (revision 4361) @@ -1,8 +1,8 @@ -// Copyright (C) Stichting Deltares 2018. All rights reserved. -// -// This file is part of the Dam Piping Kernels. -// -// The Dam Macrostability Kernel is free software: you can redistribute it and/or modify +// Copyright (C) Stichting Deltares 2023. All rights reserved. +// +// This file is part of the Dam Piping Kernel. +// +// The Dam Piping Kernel is free software: you can redistribute it and/or modify // it under the terms of the GNU Affero General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. @@ -11,28 +11,28 @@ // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU Affero General Public License for more details. -// +// // You should have received a copy of the GNU Affero 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. -using Deltares.DamPiping.BlighCalculator; using System; +using System.Collections.Generic; +using Deltares.DamPiping.BlighCalculator; using NUnit.Framework; namespace Deltares.DamPiping.BlighCalculatorTests { [TestFixture] public class PipingCalculatorBlighTests { - [Test] public void TestIf64Bit() { - var ls = IntPtr.Size; + int ls = IntPtr.Size; Assert.AreEqual(8, ls); Assert.That(Environment.Is64BitProcess, Is.True); } @@ -65,7 +65,7 @@ Rc = 0.3, DTotal = 5.0, SeepageLength = 40.5, - D70 = 180.0 + D70 = 180.0 }; calculator.Calculate(); Assert.AreEqual(4.5, calculator.FoSp, diff); @@ -78,7 +78,7 @@ // expected results are based on code in 'https://repos.deltares.nl/repos/dam/dam classic' revision 190 var calculator = new PipingCalculatorBligh(); calculator.D70 = 180.0; // d50 < 150 - var factor = calculator.CreepFactor(); + double factor = calculator.CreepFactor(); Assert.AreEqual(18.0, factor); calculator.D70 = 200; // 150 < d50 < 300 @@ -106,7 +106,7 @@ Rc = 0.3, DTotal = 2.0 }; - var reducedFall = calculator.GetReducedFall(); + double reducedFall = calculator.GetReducedFall(); Assert.AreEqual(0.40, reducedFall, cTolerance); calculator.HRiver = 0.0; @@ -125,7 +125,7 @@ var hCritical = 3.65; var reducedFall = 1.00; - var safetyFactor = PipingCalculatorBligh.DetermineFactorOfSafety(hCritical, reducedFall); + double safetyFactor = PipingCalculatorBligh.DetermineFactorOfSafety(hCritical, reducedFall); Assert.AreEqual(3.65, safetyFactor, cTolerance); hCritical = 3.65; @@ -158,15 +158,15 @@ SeepageLength = 40.5, D70 = 180.0 }; - var originalErrors = calculator.Validate(); + List originalErrors = calculator.Validate(); calculator.HRiver = double.NaN; calculator.HExit = double.NaN; calculator.Rc = double.NaN; calculator.DTotal = double.NaN; calculator.SeepageLength = double.NaN; calculator.D70 = double.NaN; - var nanErrors = calculator.Validate(); + List nanErrors = calculator.Validate(); Assert.AreEqual(originalErrors.Count + 6, nanErrors.Count); // D70 is allowed to be null @@ -188,10 +188,13 @@ SeepageLength = 40.5, D70 = 180.0 }; - var errors = calculator.Validate(); + List errors = calculator.Validate(); Assert.AreEqual(1, errors.Count); var expectedMessageEN = "Rc may not be less than 0."; - CollectionAssert.AreEqual(new[] {expectedMessageEN}, errors); + CollectionAssert.AreEqual(new[] + { + expectedMessageEN + }, errors); } [Test] @@ -207,10 +210,13 @@ SeepageLength = 40.5, D70 = 180.0 }; - var errors = calculator.Validate(); + List errors = calculator.Validate(); Assert.AreEqual(1, errors.Count); var expectedMessageNL = "De waarde voor de dempingsfactor mag niet lager dan 0 zijn."; - CollectionAssert.AreEqual(new[] { expectedMessageNL }, errors); + CollectionAssert.AreEqual(new[] + { + expectedMessageNL + }, errors); } [Test] @@ -226,11 +232,13 @@ SeepageLength = 40.5, D70 = 180.0 }; - var errors = calculator.Validate(); + List errors = calculator.Validate(); Assert.AreEqual(1, errors.Count); var expectedMessageEN = "De term HRiver - HExit - (Rc*DTotal) mag niet nul zijn."; - CollectionAssert.AreEqual(new[] { expectedMessageEN }, errors); + CollectionAssert.AreEqual(new[] + { + expectedMessageEN + }, errors); } - } -} +} \ No newline at end of file Index: DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator/Deltares.DamPiping.BlighCalculator.csproj =================================================================== diff -u -r4360 -r4361 --- DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator/Deltares.DamPiping.BlighCalculator.csproj (.../Deltares.DamPiping.BlighCalculator.csproj) (revision 4360) +++ DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator/Deltares.DamPiping.BlighCalculator.csproj (.../Deltares.DamPiping.BlighCalculator.csproj) (revision 4361) @@ -1,5 +1,5 @@ - + net6.0 enable Index: DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator.Tests/Properties/AssemblyInfo.cs =================================================================== diff -u -r4360 -r4361 --- DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator.Tests/Properties/AssemblyInfo.cs (.../AssemblyInfo.cs) (revision 4360) +++ DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator.Tests/Properties/AssemblyInfo.cs (.../AssemblyInfo.cs) (revision 4361) @@ -1,8 +1,8 @@ -// Copyright (C) Stichting Deltares 2018. All rights reserved. -// -// This file is part of the Dam Piping Kernels. -// -// The Dam Macrostability Kernel is free software: you can redistribute it and/or modify +// Copyright (C) Stichting Deltares 2023. All rights reserved. +// +// This file is part of the Dam Piping Kernel. +// +// The Dam Piping Kernel is free software: you can redistribute it and/or modify // it under the terms of the GNU Affero General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. @@ -11,17 +11,15 @@ // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU Affero General Public License for more details. -// +// // You should have received a copy of the GNU Affero 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. -using System.Reflection; using System.Runtime.InteropServices; [assembly: ComVisible(false)] -[assembly: Guid("8b92cbaf-286b-44b1-9165-5b7cfd320772")] - +[assembly: Guid("8b92cbaf-286b-44b1-9165-5b7cfd320772")] \ No newline at end of file Index: DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator/Properties/Resources.nl-NL.resx =================================================================== diff -u -r878 -r4361 --- DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator/Properties/Resources.nl-NL.resx (.../Resources.nl-NL.resx) (revision 878) +++ DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator/Properties/Resources.nl-NL.resx (.../Resources.nl-NL.resx) (revision 4361) @@ -1,129 +1,134 @@  - - - - - - - + + + + - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, + PublicKeyToken=b77a5c561934e089 + + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, + PublicKeyToken=b77a5c561934e089 + + + Parameter {0} heeft geen waarde (NaN). - + De term HRiver - HExit - (Rc*DTotal) mag niet nul zijn. - + De waarde voor de dempingsfactor mag niet lager dan 0 zijn. \ No newline at end of file Index: DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator/PipingCalculatorBligh.cs =================================================================== diff -u -r4360 -r4361 --- DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator/PipingCalculatorBligh.cs (.../PipingCalculatorBligh.cs) (revision 4360) +++ DamFailureMechanisms/damPiping/trunk/src/Deltares.DamPiping.BlighCalculator/PipingCalculatorBligh.cs (.../PipingCalculatorBligh.cs) (revision 4361) @@ -2,7 +2,7 @@ // // This file is part of the Dam Piping Kernel. // -// Dam Piping Kernel is free software: you can redistribute it and/or modify +// The Dam Piping Kernel is free software: you can redistribute it and/or modify // it under the terms of the GNU Affero General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. @@ -19,8 +19,6 @@ // Stichting Deltares and remain full property of Stichting Deltares at all times. // All rights reserved. -using System; -using System.Collections.Generic; using Deltares.DamPiping.BlighCalculator.Properties; namespace Deltares.DamPiping.BlighCalculator