Index: DamEngine/trunk/src/Deltares.DamEngine.Data/Properties/Resources.Designer.cs
===================================================================
diff -u -r1215 -r1387
--- DamEngine/trunk/src/Deltares.DamEngine.Data/Properties/Resources.Designer.cs (.../Resources.Designer.cs) (revision 1215)
+++ DamEngine/trunk/src/Deltares.DamEngine.Data/Properties/Resources.Designer.cs (.../Resources.Designer.cs) (revision 1387)
@@ -79,6 +79,15 @@
}
///
+ /// Looks up a localized string similar to GetPointSegmentIncluding(): End value is smaller than the start value.
+ ///
+ internal static string GetPointSegmentIncludingEndValueSmallerThanStartValue {
+ get {
+ return ResourceManager.GetString("GetPointSegmentIncludingEndValueSmallerThanStartValue", resourceCulture);
+ }
+ }
+
+ ///
/// Looks up a localized string similar to In combining the aquifer layer for 1D profile {0}, different water pressure interpolation models are used in the layers concerned which is not allowed..
///
internal static string SoilProfile1DAquiferLayerCombiner_CombineLayers_InconsistentWaterpressureInterpolationModel {
Index: DamEngine/trunk/src/Deltares.DamEngine.Data/Properties/Resources.nl-NL.resx
===================================================================
diff -u -r1215 -r1387
--- DamEngine/trunk/src/Deltares.DamEngine.Data/Properties/Resources.nl-NL.resx (.../Resources.nl-NL.resx) (revision 1215)
+++ DamEngine/trunk/src/Deltares.DamEngine.Data/Properties/Resources.nl-NL.resx (.../Resources.nl-NL.resx) (revision 1387)
@@ -117,6 +117,9 @@
System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+ GetPointSegmentIncluding(): Eindwaarde is kleiner dan de startwaarde
+
GetCotangentOfInnerSlope heeft karakteristiek punt insteek berm of dijk teen polderzijde nodig.
Index: DamEngine/trunk/src/Deltares.DamEngine.Data/Geotechnics/SurfaceLine2.cs
===================================================================
diff -u -r955 -r1387
--- DamEngine/trunk/src/Deltares.DamEngine.Data/Geotechnics/SurfaceLine2.cs (.../SurfaceLine2.cs) (revision 955)
+++ DamEngine/trunk/src/Deltares.DamEngine.Data/Geotechnics/SurfaceLine2.cs (.../SurfaceLine2.cs) (revision 1387)
@@ -23,6 +23,7 @@
using System.Collections.Generic;
using System.Linq;
using Deltares.DamEngine.Data.Geometry;
+using Deltares.DamEngine.Data.Properties;
using Deltares.DamEngine.Data.Standard;
using Deltares.DamEngine.Data.Standard.Language;
using Deltares.DamEngine.Data.Standard.Validation;
@@ -194,7 +195,7 @@
double x = point.X;
return (x >= startX || x.AlmostEquals(startX, GeometryPoint.Precision))
- && (x < endX || x.AlmostEquals(endX, GeometryPoint.Precision));
+ && (x <= endX || x.AlmostEquals(endX, GeometryPoint.Precision));
}
///
@@ -208,7 +209,7 @@
{
if (endX < startX)
{
- throw new ArgumentException("End value is smaller then the start value");
+ throw new ArgumentException(Resources.GetPointSegmentIncludingEndValueSmallerThanStartValue);
}
return from point in PointsOrderdByX
Index: DamEngine/trunk/src/Deltares.DamEngine.Data/Properties/Resources.resx
===================================================================
diff -u -r1215 -r1387
--- DamEngine/trunk/src/Deltares.DamEngine.Data/Properties/Resources.resx (.../Resources.resx) (revision 1215)
+++ DamEngine/trunk/src/Deltares.DamEngine.Data/Properties/Resources.resx (.../Resources.resx) (revision 1387)
@@ -123,6 +123,9 @@
GetCotangentOfInnerSlope requires characteristic point DikeTopAtPolder to be defined.
+
+ GetPointSegmentIncluding(): End value is smaller than the start value
+
In combining the aquifer layer for 1D profile {0}, different water pressure interpolation models are used in the layers concerned which is not allowed.
Index: DamEngine/trunk/src/Deltares.DamEngine.Calculators.Tests/DikesDesign/SurfaceLineHeightAdapterTest.cs
===================================================================
diff -u -r1090 -r1387
--- DamEngine/trunk/src/Deltares.DamEngine.Calculators.Tests/DikesDesign/SurfaceLineHeightAdapterTest.cs (.../SurfaceLineHeightAdapterTest.cs) (revision 1090)
+++ DamEngine/trunk/src/Deltares.DamEngine.Calculators.Tests/DikesDesign/SurfaceLineHeightAdapterTest.cs (.../SurfaceLineHeightAdapterTest.cs) (revision 1387)
@@ -447,6 +447,9 @@
}
}
+ ///
+ /// This tests with a realistic surfaceline which contains all possible relevant characteristic points
+ ///
[Test]
public void AdaptedSurfaceLineWithTrafficLoadPointsShouldAdjustThosePoints1()
{
@@ -460,6 +463,9 @@
Assert.AreEqual(newSurfaceLine.CharacteristicPoints.GetGeometryPoint(CharacteristicPointType.DikeTopAtPolder).Z, newSurfaceLine.CharacteristicPoints.GetGeometryPoint(CharacteristicPointType.TrafficLoadInside).Z, cTolerance);
}
+ ///
+ /// This tests with a surfaceline that contains the minimum possible characteristic points
+ ///
[Test]
public void AdaptedSurfaceLineWithTrafficLoadPointsShouldAdjustThosePoints2()
{
@@ -889,7 +895,7 @@
}
[Test]
- public void AdaptedSurfaceLineWithNewDefinedTopWidthAndOutsideSlopeAndInsideSlope()
+ public void AdaptedSurfaceLineWithNewDefinedTopWidthAndOutsideSlopeAndInsideSlope2()
{
var surfaceLine = new SurfaceLine2
{
@@ -979,7 +985,7 @@
[Test]
[ExpectedException(typeof(SurfaceLineAdapterException))]
- public void HeightAdaptionThrowsExceptionIfSurfaceLIsNotLongEnough()
+ public void HeightAdaptionThrowsExceptionIfSurfaceLineIsNotLongEnough()
{
var surfaceLine = FactoryForSurfaceLines.CreateRealisticSurfaceLineForHeightAdapter();
var location = new Location();
Index: DamEngine/trunk/src/Deltares.DamEngine.Data/General/PlLines/PlLine.cs
===================================================================
diff -u -r1121 -r1387
--- DamEngine/trunk/src/Deltares.DamEngine.Data/General/PlLines/PlLine.cs (.../PlLine.cs) (revision 1121)
+++ DamEngine/trunk/src/Deltares.DamEngine.Data/General/PlLines/PlLine.cs (.../PlLine.cs) (revision 1387)
@@ -81,7 +81,7 @@
if (endX < startX)
throw new ArgumentException("End value is smaller then the start value");
- return from point in this.PointsOrderdByX
+ return from point in this.PointsOrderedByX
where point != null && (point.X > startX && point.X < endX)
orderby point.X ascending
select point;
@@ -116,7 +116,7 @@
}
}
- private IEnumerable PointsOrderdByX
+ private IEnumerable PointsOrderedByX
{
get { return this.Points.OrderBy(p => p.X); }
}