Index: DamEngine/trunk/src/Deltares.DamEngine.Data/Geometry/GeometryLoop.cs
===================================================================
diff -u -r4884 -r4897
--- DamEngine/trunk/src/Deltares.DamEngine.Data/Geometry/GeometryLoop.cs (.../GeometryLoop.cs) (revision 4884)
+++ DamEngine/trunk/src/Deltares.DamEngine.Data/Geometry/GeometryLoop.cs (.../GeometryLoop.cs) (revision 4897)
@@ -30,8 +30,6 @@
///
public class GeometryLoop : GeometryPointString
{
- private readonly Routines2D routines2D = new Routines2D();
-
///
/// List of points that describe the physical surface line or surface.
///
@@ -122,7 +120,7 @@
public bool IsClockWise()
{
List polyGon = GetLocalPoint2DList();
- Clockwise isClockWise = routines2D.IsClockWise(polyGon);
+ Clockwise isClockWise = Routines2D.IsClockWise(polyGon);
if (isClockWise == Clockwise.NotEnoughUniquePoints)
{
throw new NotEnoughUniquePointsException();
@@ -142,13 +140,14 @@
/// True if continuous, false if not
public bool IsContinuous()
{
- for (int i = 0; i < CurveList.Count - 1; i++)
+ for (var i = 0; i < CurveList.Count - 1; i++)
{
if (CurveList[i].EndPoint != CurveList[i + 1].HeadPoint)
{
return false;
}
}
+
return true;
}
@@ -159,7 +158,7 @@
///
public bool IsPointInLoopArea(Point2D aPoint)
{
- return routines2D.CheckIfPointIsInPolygon(this, aPoint.X, aPoint.Z) != PointInPolygon.OutsidePolygon;
+ return Routines2D.CheckIfPointIsInPolygon(this, aPoint.X, aPoint.Z) != PointInPolygon.OutsidePolygon;
}
///