Index: Core/Components/src/Core.Components.DotSpatial/Converter/FeatureBasedMapDataConverter.cs
===================================================================
diff -u -rc5008a06ddbdc34516ee880e44c719266185546c -r24d0467d90ae44ab5630a29f761f4e33ced2a5f4
--- Core/Components/src/Core.Components.DotSpatial/Converter/FeatureBasedMapDataConverter.cs (.../FeatureBasedMapDataConverter.cs) (revision c5008a06ddbdc34516ee880e44c719266185546c)
+++ Core/Components/src/Core.Components.DotSpatial/Converter/FeatureBasedMapDataConverter.cs (.../FeatureBasedMapDataConverter.cs) (revision 24d0467d90ae44ab5630a29f761f4e33ced2a5f4)
@@ -28,7 +28,6 @@
using Core.Components.Gis.Data;
using Core.Components.Gis.Features;
using Core.Components.Gis.Theme;
-using Core.Components.Gis.Theme.Criteria;
using DotSpatial.Controls;
using DotSpatial.Data;
using DotSpatial.Projections;
Index: Core/Components/src/Core.Components.Gis/Core.Components.Gis.csproj
===================================================================
diff -u -rc5008a06ddbdc34516ee880e44c719266185546c -r24d0467d90ae44ab5630a29f761f4e33ced2a5f4
--- Core/Components/src/Core.Components.Gis/Core.Components.Gis.csproj (.../Core.Components.Gis.csproj) (revision c5008a06ddbdc34516ee880e44c719266185546c)
+++ Core/Components/src/Core.Components.Gis/Core.Components.Gis.csproj (.../Core.Components.Gis.csproj) (revision 24d0467d90ae44ab5630a29f761f4e33ced2a5f4)
@@ -13,9 +13,9 @@
-
-
-
+
+
+
Index: Core/Components/src/Core.Components.Gis/Theme/CategoryTheme.cs
===================================================================
diff -u -r0eefe4fd03e9a34a58295a2f94705597189df4cd -r24d0467d90ae44ab5630a29f761f4e33ced2a5f4
--- Core/Components/src/Core.Components.Gis/Theme/CategoryTheme.cs (.../CategoryTheme.cs) (revision 0eefe4fd03e9a34a58295a2f94705597189df4cd)
+++ Core/Components/src/Core.Components.Gis/Theme/CategoryTheme.cs (.../CategoryTheme.cs) (revision 24d0467d90ae44ab5630a29f761f4e33ced2a5f4)
@@ -21,7 +21,6 @@
using System;
using System.Drawing;
-using Core.Components.Gis.Theme.Criteria;
namespace Core.Components.Gis.Theme
{
Fisheye: Tag 24d0467d90ae44ab5630a29f761f4e33ced2a5f4 refers to a dead (removed) revision in file `Core/Components/src/Core.Components.Gis/Theme/Criteria/ICriteria.cs'.
Fisheye: No comparison available. Pass `N' to diff?
Fisheye: Tag 24d0467d90ae44ab5630a29f761f4e33ced2a5f4 refers to a dead (removed) revision in file `Core/Components/src/Core.Components.Gis/Theme/Criteria/ValueCriteria.cs'.
Fisheye: No comparison available. Pass `N' to diff?
Fisheye: Tag 24d0467d90ae44ab5630a29f761f4e33ced2a5f4 refers to a dead (removed) revision in file `Core/Components/src/Core.Components.Gis/Theme/Criteria/ValueCriteriaOperator.cs'.
Fisheye: No comparison available. Pass `N' to diff?
Index: Core/Components/src/Core.Components.Gis/Theme/ICriteria.cs
===================================================================
diff -u
--- Core/Components/src/Core.Components.Gis/Theme/ICriteria.cs (revision 0)
+++ Core/Components/src/Core.Components.Gis/Theme/ICriteria.cs (revision 24d0467d90ae44ab5630a29f761f4e33ced2a5f4)
@@ -0,0 +1,28 @@
+// Copyright (C) Stichting Deltares 2017. 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 Lesser 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 Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser 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.
+
+namespace Core.Components.Gis.Theme
+{
+ ///
+ /// Interface for criteria to apply to classify data.
+ ///
+ public interface ICriteria {}
+}
\ No newline at end of file
Index: Core/Components/src/Core.Components.Gis/Theme/ValueCriteria.cs
===================================================================
diff -u
--- Core/Components/src/Core.Components.Gis/Theme/ValueCriteria.cs (revision 0)
+++ Core/Components/src/Core.Components.Gis/Theme/ValueCriteria.cs (revision 24d0467d90ae44ab5630a29f761f4e33ced2a5f4)
@@ -0,0 +1,62 @@
+// Copyright (C) Stichting Deltares 2017. 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 Lesser 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 Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser 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;
+using System.ComponentModel;
+
+namespace Core.Components.Gis.Theme
+{
+ ///
+ /// Criteria to be used for equal or unequal values.
+ ///
+ public class ValueCriteria : ICriteria
+ {
+ ///
+ /// Creates a new instance of .
+ ///
+ /// The belonging to this criteria.
+ /// The value to apply when using this criteria.
+ /// Thrown when
+ /// contains an invalid value for .
+ public ValueCriteria(ValueCriteriaOperator valueOperator, double value)
+ {
+ if (!Enum.IsDefined(typeof(ValueCriteriaOperator), valueOperator))
+ {
+ throw new InvalidEnumArgumentException(nameof(valueOperator),
+ (int) valueOperator,
+ typeof(ValueCriteriaOperator));
+ }
+
+ ValueOperator = valueOperator;
+ Value = value;
+ }
+
+ ///
+ /// Gets the operator for the criteria.
+ ///
+ public ValueCriteriaOperator ValueOperator { get; }
+
+ ///
+ /// Gets the value that belongs to the criteria.
+ ///
+ public double Value { get; }
+ }
+}
\ No newline at end of file
Index: Core/Components/src/Core.Components.Gis/Theme/ValueCriteriaOperator.cs
===================================================================
diff -u
--- Core/Components/src/Core.Components.Gis/Theme/ValueCriteriaOperator.cs (revision 0)
+++ Core/Components/src/Core.Components.Gis/Theme/ValueCriteriaOperator.cs (revision 24d0467d90ae44ab5630a29f761f4e33ced2a5f4)
@@ -0,0 +1,39 @@
+// Copyright (C) Stichting Deltares 2017. 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 Lesser 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 Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser 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.
+
+namespace Core.Components.Gis.Theme
+{
+ ///
+ /// Defines the operators of an equality based criterion.
+ ///
+ public enum ValueCriteriaOperator
+ {
+ ///
+ /// Represents the operator '=='
+ ///
+ EqualValue = 1,
+
+ ///
+ /// Represents the operator '!='
+ ///
+ UnequalValue = 2
+ }
+}
\ No newline at end of file
Index: Core/Components/test/Core.Components.DotSpatial.Test/Converter/FeatureBasedMapDataConverterTest.cs
===================================================================
diff -u -rc5008a06ddbdc34516ee880e44c719266185546c -r24d0467d90ae44ab5630a29f761f4e33ced2a5f4
--- Core/Components/test/Core.Components.DotSpatial.Test/Converter/FeatureBasedMapDataConverterTest.cs (.../FeatureBasedMapDataConverterTest.cs) (revision c5008a06ddbdc34516ee880e44c719266185546c)
+++ Core/Components/test/Core.Components.DotSpatial.Test/Converter/FeatureBasedMapDataConverterTest.cs (.../FeatureBasedMapDataConverterTest.cs) (revision 24d0467d90ae44ab5630a29f761f4e33ced2a5f4)
@@ -32,7 +32,6 @@
using Core.Components.Gis.Geometries;
using Core.Components.Gis.TestUtil.Theme;
using Core.Components.Gis.Theme;
-using Core.Components.Gis.Theme.Criteria;
using DotSpatial.Controls;
using DotSpatial.Data;
using DotSpatial.Projections;
Index: Core/Components/test/Core.Components.DotSpatial.Test/Converter/MapLineDataConverterTest.cs
===================================================================
diff -u -rc5008a06ddbdc34516ee880e44c719266185546c -r24d0467d90ae44ab5630a29f761f4e33ced2a5f4
--- Core/Components/test/Core.Components.DotSpatial.Test/Converter/MapLineDataConverterTest.cs (.../MapLineDataConverterTest.cs) (revision c5008a06ddbdc34516ee880e44c719266185546c)
+++ Core/Components/test/Core.Components.DotSpatial.Test/Converter/MapLineDataConverterTest.cs (.../MapLineDataConverterTest.cs) (revision 24d0467d90ae44ab5630a29f761f4e33ced2a5f4)
@@ -31,7 +31,6 @@
using Core.Components.Gis.Geometries;
using Core.Components.Gis.Style;
using Core.Components.Gis.Theme;
-using Core.Components.Gis.Theme.Criteria;
using DotSpatial.Controls;
using DotSpatial.Data;
using DotSpatial.Symbology;
Index: Core/Components/test/Core.Components.DotSpatial.Test/Converter/MapPointDataConverterTest.cs
===================================================================
diff -u -rc5008a06ddbdc34516ee880e44c719266185546c -r24d0467d90ae44ab5630a29f761f4e33ced2a5f4
--- Core/Components/test/Core.Components.DotSpatial.Test/Converter/MapPointDataConverterTest.cs (.../MapPointDataConverterTest.cs) (revision c5008a06ddbdc34516ee880e44c719266185546c)
+++ Core/Components/test/Core.Components.DotSpatial.Test/Converter/MapPointDataConverterTest.cs (.../MapPointDataConverterTest.cs) (revision 24d0467d90ae44ab5630a29f761f4e33ced2a5f4)
@@ -30,7 +30,6 @@
using Core.Components.Gis.Geometries;
using Core.Components.Gis.Style;
using Core.Components.Gis.Theme;
-using Core.Components.Gis.Theme.Criteria;
using DotSpatial.Controls;
using DotSpatial.Data;
using DotSpatial.Symbology;
Index: Core/Components/test/Core.Components.DotSpatial.Test/Converter/MapPolygonDataConverterTest.cs
===================================================================
diff -u -rc5008a06ddbdc34516ee880e44c719266185546c -r24d0467d90ae44ab5630a29f761f4e33ced2a5f4
--- Core/Components/test/Core.Components.DotSpatial.Test/Converter/MapPolygonDataConverterTest.cs (.../MapPolygonDataConverterTest.cs) (revision c5008a06ddbdc34516ee880e44c719266185546c)
+++ Core/Components/test/Core.Components.DotSpatial.Test/Converter/MapPolygonDataConverterTest.cs (.../MapPolygonDataConverterTest.cs) (revision 24d0467d90ae44ab5630a29f761f4e33ced2a5f4)
@@ -30,7 +30,6 @@
using Core.Components.Gis.Geometries;
using Core.Components.Gis.Style;
using Core.Components.Gis.Theme;
-using Core.Components.Gis.Theme.Criteria;
using DotSpatial.Controls;
using DotSpatial.Data;
using DotSpatial.Symbology;
Index: Core/Components/test/Core.Components.Gis.Test/Core.Components.Gis.Test.csproj
===================================================================
diff -u -rc5008a06ddbdc34516ee880e44c719266185546c -r24d0467d90ae44ab5630a29f761f4e33ced2a5f4
--- Core/Components/test/Core.Components.Gis.Test/Core.Components.Gis.Test.csproj (.../Core.Components.Gis.Test.csproj) (revision c5008a06ddbdc34516ee880e44c719266185546c)
+++ Core/Components/test/Core.Components.Gis.Test/Core.Components.Gis.Test.csproj (.../Core.Components.Gis.Test.csproj) (revision 24d0467d90ae44ab5630a29f761f4e33ced2a5f4)
@@ -20,7 +20,7 @@
-
+
Index: Core/Components/test/Core.Components.Gis.Test/Theme/CategoryThemeTest.cs
===================================================================
diff -u -r0eefe4fd03e9a34a58295a2f94705597189df4cd -r24d0467d90ae44ab5630a29f761f4e33ced2a5f4
--- Core/Components/test/Core.Components.Gis.Test/Theme/CategoryThemeTest.cs (.../CategoryThemeTest.cs) (revision 0eefe4fd03e9a34a58295a2f94705597189df4cd)
+++ Core/Components/test/Core.Components.Gis.Test/Theme/CategoryThemeTest.cs (.../CategoryThemeTest.cs) (revision 24d0467d90ae44ab5630a29f761f4e33ced2a5f4)
@@ -23,7 +23,6 @@
using System.Drawing;
using Core.Common.TestUtil;
using Core.Components.Gis.Theme;
-using Core.Components.Gis.Theme.Criteria;
using NUnit.Framework;
using Rhino.Mocks;
Fisheye: Tag 24d0467d90ae44ab5630a29f761f4e33ced2a5f4 refers to a dead (removed) revision in file `Core/Components/test/Core.Components.Gis.Test/Theme/Criteria/ValueCriteriaTest.cs'.
Fisheye: No comparison available. Pass `N' to diff?
Index: Core/Components/test/Core.Components.Gis.Test/Theme/ValueCriteriaTest.cs
===================================================================
diff -u
--- Core/Components/test/Core.Components.Gis.Test/Theme/ValueCriteriaTest.cs (revision 0)
+++ Core/Components/test/Core.Components.Gis.Test/Theme/ValueCriteriaTest.cs (revision 24d0467d90ae44ab5630a29f761f4e33ced2a5f4)
@@ -0,0 +1,66 @@
+// Copyright (C) Stichting Deltares 2017. 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 Lesser 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 Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser 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;
+using System.ComponentModel;
+using Core.Common.TestUtil;
+using Core.Components.Gis.Theme;
+using NUnit.Framework;
+
+namespace Core.Components.Gis.Test.Theme
+{
+ [TestFixture]
+ public class ValueCriteriaTest
+ {
+ [Test]
+ public void Constructor_ReturnsExpectedProperties()
+ {
+ // Setup
+ var random = new Random(21);
+ var valueOperator = random.NextEnumValue();
+ double value = random.NextDouble();
+
+ // Call
+ var criteria = new ValueCriteria(valueOperator, value);
+
+ // Assert
+ Assert.IsInstanceOf(criteria);
+ Assert.AreEqual(valueOperator, criteria.ValueOperator);
+ Assert.AreEqual(value, criteria.Value);
+ }
+
+ [Test]
+ public void Constructor_InvalidEqualityBasedOperator_ThrowsInvalidEnumArgumentException()
+ {
+ // Setup
+ var random = new Random(21);
+ const ValueCriteriaOperator invalidOperator = (ValueCriteriaOperator) 9999;
+
+ // Call
+ TestDelegate call = () => new ValueCriteria(invalidOperator, random.NextDouble());
+
+ // Assert
+ string expectedMessage = $"The value of argument 'valueOperator' ({invalidOperator}) is invalid for Enum type '{nameof(ValueCriteriaOperator)}'.";
+ string parameterName = TestHelper.AssertThrowsArgumentExceptionAndTestMessage(call, expectedMessage).ParamName;
+ Assert.AreEqual("valueOperator", parameterName);
+ }
+ }
+}
\ No newline at end of file
Index: Core/Components/test/Core.Components.Gis.TestUtil.Test/Theme/TestCriteriaTest.cs
===================================================================
diff -u -r3c41a03f6a1173872af5d8507465e291f9e3f8f2 -r24d0467d90ae44ab5630a29f761f4e33ced2a5f4
--- Core/Components/test/Core.Components.Gis.TestUtil.Test/Theme/TestCriteriaTest.cs (.../TestCriteriaTest.cs) (revision 3c41a03f6a1173872af5d8507465e291f9e3f8f2)
+++ Core/Components/test/Core.Components.Gis.TestUtil.Test/Theme/TestCriteriaTest.cs (.../TestCriteriaTest.cs) (revision 24d0467d90ae44ab5630a29f761f4e33ced2a5f4)
@@ -20,7 +20,7 @@
// All rights reserved.
using Core.Components.Gis.TestUtil.Theme;
-using Core.Components.Gis.Theme.Criteria;
+using Core.Components.Gis.Theme;
using NUnit.Framework;
namespace Core.Components.Gis.TestUtil.Test.Theme
Index: Core/Components/test/Core.Components.Gis.TestUtil/Theme/TestCriteria.cs
===================================================================
diff -u -r3c41a03f6a1173872af5d8507465e291f9e3f8f2 -r24d0467d90ae44ab5630a29f761f4e33ced2a5f4
--- Core/Components/test/Core.Components.Gis.TestUtil/Theme/TestCriteria.cs (.../TestCriteria.cs) (revision 3c41a03f6a1173872af5d8507465e291f9e3f8f2)
+++ Core/Components/test/Core.Components.Gis.TestUtil/Theme/TestCriteria.cs (.../TestCriteria.cs) (revision 24d0467d90ae44ab5630a29f761f4e33ced2a5f4)
@@ -19,7 +19,7 @@
// Stichting Deltares and remain full property of Stichting Deltares at all times.
// All rights reserved.
-using Core.Components.Gis.Theme.Criteria;
+using Core.Components.Gis.Theme;
namespace Core.Components.Gis.TestUtil.Theme
{
Index: Demo/Ringtoets/src/Demo.Ringtoets/Commands/OpenThematicalMapViewCommand.cs
===================================================================
diff -u -r4f5c5afab904ec8570bb482a9845b56f074a26e4 -r24d0467d90ae44ab5630a29f761f4e33ced2a5f4
--- Demo/Ringtoets/src/Demo.Ringtoets/Commands/OpenThematicalMapViewCommand.cs (.../OpenThematicalMapViewCommand.cs) (revision 4f5c5afab904ec8570bb482a9845b56f074a26e4)
+++ Demo/Ringtoets/src/Demo.Ringtoets/Commands/OpenThematicalMapViewCommand.cs (.../OpenThematicalMapViewCommand.cs) (revision 24d0467d90ae44ab5630a29f761f4e33ced2a5f4)
@@ -30,7 +30,6 @@
using Core.Components.Gis.Features;
using Core.Components.Gis.Geometries;
using Core.Components.Gis.Theme;
-using Core.Components.Gis.Theme.Criteria;
using Demo.Ringtoets.Properties;
namespace Demo.Ringtoets.Commands