Index: Demo/Ringtoets/src/Demo.Ringtoets/Commands/AddNewDemoAssessmentSectionCommand.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Demo/Ringtoets/src/Demo.Ringtoets/Commands/AddNewDemoAssessmentSectionCommand.cs (.../AddNewDemoAssessmentSectionCommand.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Demo/Ringtoets/src/Demo.Ringtoets/Commands/AddNewDemoAssessmentSectionCommand.cs (.../AddNewDemoAssessmentSectionCommand.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -117,14 +117,14 @@
targetConfiguration.SelectedCapabilityIdentifier,
targetConfiguration.PreferredFormat);
- demoAssessmentSection.BackgroundMapData2.Name = targetConfiguration.Name;
- demoAssessmentSection.BackgroundMapData2.BackgroundMapDataType = BackgroundMapDataType.Wmts;
- demoAssessmentSection.BackgroundMapData2.IsVisible = targetConfiguration.IsVisible;
- demoAssessmentSection.BackgroundMapData2.Transparency = targetConfiguration.Transparency;
- demoAssessmentSection.BackgroundMapData2.IsConfigured = targetConfiguration.IsConfigured;
- demoAssessmentSection.BackgroundMapData2.Parameters.Add("SourceCapabilitiesUrl", targetConfiguration.SourceCapabilitiesUrl);
- demoAssessmentSection.BackgroundMapData2.Parameters.Add("SelectedCapabilityIdentifier", targetConfiguration.SelectedCapabilityIdentifier);
- demoAssessmentSection.BackgroundMapData2.Parameters.Add("PreferredFormat", targetConfiguration.PreferredFormat);
+ demoAssessmentSection.BackgroundData.Name = targetConfiguration.Name;
+ demoAssessmentSection.BackgroundData.BackgroundMapDataType = BackgroundMapDataType.Wmts;
+ demoAssessmentSection.BackgroundData.IsVisible = targetConfiguration.IsVisible;
+ demoAssessmentSection.BackgroundData.Transparency = targetConfiguration.Transparency;
+ demoAssessmentSection.BackgroundData.IsConfigured = targetConfiguration.IsConfigured;
+ demoAssessmentSection.BackgroundData.Parameters.Add("SourceCapabilitiesUrl", targetConfiguration.SourceCapabilitiesUrl);
+ demoAssessmentSection.BackgroundData.Parameters.Add("SelectedCapabilityIdentifier", targetConfiguration.SelectedCapabilityIdentifier);
+ demoAssessmentSection.BackgroundData.Parameters.Add("PreferredFormat", targetConfiguration.PreferredFormat);
}
private void InitializeDemoReferenceLine(AssessmentSection demoAssessmentSection)
Index: Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Forms/Views/ClosingStructuresFailureMechanismView.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Forms/Views/ClosingStructuresFailureMechanismView.cs (.../ClosingStructuresFailureMechanismView.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/ClosingStructures/src/Ringtoets.ClosingStructures.Forms/Views/ClosingStructuresFailureMechanismView.cs (.../ClosingStructuresFailureMechanismView.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -152,11 +152,11 @@
calculationGroupObserver.Observable = data.WrappedData.CalculationsGroup;
calculationObserver.Observable = data.WrappedData.CalculationsGroup;
- backgroundMapDataObserver.Observable = data.Parent.BackgroundMapData2;
+ backgroundMapDataObserver.Observable = data.Parent.BackgroundData;
SetMapDataFeatures();
- backgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(data.Parent.BackgroundMapData2);
+ backgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(data.Parent.BackgroundData);
Map.Data = mapDataCollection;
Map.BackgroundMapData = backgroundMapData;
@@ -192,7 +192,7 @@
private void UpdateBackgroundMapData()
{
- RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(backgroundMapData, data.Parent.BackgroundMapData2);
+ RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(backgroundMapData, data.Parent.BackgroundData);
backgroundMapData.NotifyObservers();
}
Index: Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Forms.Test/Views/ClosingStructuresFailureMechanismViewTest.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Forms.Test/Views/ClosingStructuresFailureMechanismViewTest.cs (.../ClosingStructuresFailureMechanismViewTest.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/ClosingStructures/test/Ringtoets.ClosingStructures.Forms.Test/Views/ClosingStructuresFailureMechanismViewTest.cs (.../ClosingStructuresFailureMechanismViewTest.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -117,7 +117,7 @@
view.Data = failureMechanismContext;
// Assert
- WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(assessmentSection.BackgroundMapData2);
+ WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(assessmentSection.BackgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
@@ -184,7 +184,7 @@
Assert.AreSame(failureMechanismContext, view.Data);
AssertEmptyMapData(view.Map.Data);
WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(
- assessmentSection.BackgroundMapData2);
+ assessmentSection.BackgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
@@ -434,19 +434,19 @@
var assessmentSection = new ObservableTestAssessmentSectionStub();
view.Data = new ClosingStructuresFailureMechanismContext(new ClosingStructuresFailureMechanism(), assessmentSection);
- BackgroundMapData backgroundMapData = assessmentSection.BackgroundMapData2;
+ BackgroundData backgroundData = assessmentSection.BackgroundData;
- backgroundMapData.Name = "some Name";
- backgroundMapData.Parameters["SourceCapabilitiesUrl"] = "some URL";
- backgroundMapData.Parameters["SelectedCapabilityIdentifier"] = "some Identifier";
- backgroundMapData.Parameters["PreferredFormat"] = "image/some Format";
- backgroundMapData.IsConfigured = true;
+ backgroundData.Name = "some Name";
+ backgroundData.Parameters["SourceCapabilitiesUrl"] = "some URL";
+ backgroundData.Parameters["SelectedCapabilityIdentifier"] = "some Identifier";
+ backgroundData.Parameters["PreferredFormat"] = "image/some Format";
+ backgroundData.IsConfigured = true;
// When
- backgroundMapData.NotifyObservers();
+ backgroundData.NotifyObservers();
// Then
- WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundMapData);
+ WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
Index: Ringtoets/Common/src/Ringtoets.Common.Data/AssessmentSection/BackgroundData.cs
===================================================================
diff -u
--- Ringtoets/Common/src/Ringtoets.Common.Data/AssessmentSection/BackgroundData.cs (revision 0)
+++ Ringtoets/Common/src/Ringtoets.Common.Data/AssessmentSection/BackgroundData.cs (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -0,0 +1,71 @@
+// 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.
+
+using System.Collections.Generic;
+using Core.Common.Base;
+using Core.Common.Base.Data;
+
+namespace Ringtoets.Common.Data.AssessmentSection
+{
+ ///
+ /// Class that holds information about configured background data.
+ ///
+ public class BackgroundData : Observable
+
+ {
+ ///
+ /// Creates a new .
+ ///
+ public BackgroundData()
+ {
+ IsVisible = true;
+ Transparency = new RoundedDouble(2);
+ Parameters = new Dictionary();
+ }
+
+ public string Name { get; set; }
+
+ ///
+ /// Gets or sets a value indicating whether the background is visible.
+ ///
+ public bool IsVisible { get; set; }
+
+ ///
+ /// Gets or sets the transparency of the background.
+ ///
+ public RoundedDouble Transparency { get; set; }
+
+ ///
+ /// Gets or sets the type of the background map data.
+ ///
+ public BackgroundMapDataType BackgroundMapDataType { get; set; }
+
+ ///
+ /// Gets or sets whether a background map data is configured.
+ ///
+ public bool IsConfigured { get; set; }
+
+ ///
+ /// Gets the parameters that are configured for a background map data.
+ ///
+ public IDictionary Parameters { get; }
+ }
+}
\ No newline at end of file
Fisheye: Tag 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4 refers to a dead (removed) revision in file `Ringtoets/Common/src/Ringtoets.Common.Data/AssessmentSection/BackgroundMapData.cs'.
Fisheye: No comparison available. Pass `N' to diff?
Index: Ringtoets/Common/src/Ringtoets.Common.Data/AssessmentSection/BackgroundMapDataType.cs
===================================================================
diff -u -r7342bdbb53114c7b63144219a8fa9df9a097192a -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Common/src/Ringtoets.Common.Data/AssessmentSection/BackgroundMapDataType.cs (.../BackgroundMapDataType.cs) (revision 7342bdbb53114c7b63144219a8fa9df9a097192a)
+++ Ringtoets/Common/src/Ringtoets.Common.Data/AssessmentSection/BackgroundMapDataType.cs (.../BackgroundMapDataType.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -22,7 +22,7 @@
namespace Ringtoets.Common.Data.AssessmentSection
{
///
- /// Enumeration that defines the possible types of a .
+ /// Enumeration that defines the possible types of a .
///
public enum BackgroundMapDataType
{
Index: Ringtoets/Common/src/Ringtoets.Common.Data/AssessmentSection/IAssessmentSection.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Common/src/Ringtoets.Common.Data/AssessmentSection/IAssessmentSection.cs (.../IAssessmentSection.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/Common/src/Ringtoets.Common.Data/AssessmentSection/IAssessmentSection.cs (.../IAssessmentSection.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -76,7 +76,7 @@
///
BackgroundMapDataContainer BackgroundMapData { get; }
- BackgroundMapData BackgroundMapData2 { get; }
+ BackgroundData BackgroundData { get; }
///
/// Gets the failure mechanisms corresponding to the assessment section.
Index: Ringtoets/Common/src/Ringtoets.Common.Data/Ringtoets.Common.Data.csproj
===================================================================
diff -u -r7342bdbb53114c7b63144219a8fa9df9a097192a -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Common/src/Ringtoets.Common.Data/Ringtoets.Common.Data.csproj (.../Ringtoets.Common.Data.csproj) (revision 7342bdbb53114c7b63144219a8fa9df9a097192a)
+++ Ringtoets/Common/src/Ringtoets.Common.Data/Ringtoets.Common.Data.csproj (.../Ringtoets.Common.Data.csproj) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -39,7 +39,7 @@
Properties\GlobalAssembly.cs
-
+
Index: Ringtoets/Common/src/Ringtoets.Common.Forms/Views/FailureMechanismView.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Common/src/Ringtoets.Common.Forms/Views/FailureMechanismView.cs (.../FailureMechanismView.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/Common/src/Ringtoets.Common.Forms/Views/FailureMechanismView.cs (.../FailureMechanismView.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -119,11 +119,11 @@
mapDataCollection.Name = data.WrappedData.Name;
hydraulicBoundaryDatabaseObserver.Observable = data.Parent.HydraulicBoundaryDatabase;
- backgroundMapDataObserver.Observable = data.Parent.BackgroundMapData2;
+ backgroundMapDataObserver.Observable = data.Parent.BackgroundData;
SetMapDataFeatures();
- backgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(data.Parent.BackgroundMapData2);
+ backgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(data.Parent.BackgroundData);
Map.Data = mapDataCollection;
Map.BackgroundMapData = backgroundMapData;
@@ -154,7 +154,7 @@
private void UpdateBackgroundMapData()
{
- RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(backgroundMapData, data.Parent.BackgroundMapData2);
+ RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(backgroundMapData, data.Parent.BackgroundData);
backgroundMapData.NotifyObservers();
}
Index: Ringtoets/Common/src/Ringtoets.Common.Forms/Views/RingtoetsBackgroundMapDataFactory.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Common/src/Ringtoets.Common.Forms/Views/RingtoetsBackgroundMapDataFactory.cs (.../RingtoetsBackgroundMapDataFactory.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/Common/src/Ringtoets.Common.Forms/Views/RingtoetsBackgroundMapDataFactory.cs (.../RingtoetsBackgroundMapDataFactory.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -31,23 +31,23 @@
public static class RingtoetsBackgroundMapDataFactory
{
///
- /// Creates from a .
+ /// Creates from a .
///
- /// The to create
+ /// The to create
/// the for.
/// The created .
- /// Thrown when
+ /// Thrown when
/// is null.
- public static WmtsMapData CreateBackgroundMapData(BackgroundMapData backgroundMapData)
+ public static WmtsMapData CreateBackgroundMapData(BackgroundData backgroundData)
{
- if (backgroundMapData == null)
+ if (backgroundData == null)
{
- throw new ArgumentNullException(nameof(backgroundMapData));
+ throw new ArgumentNullException(nameof(backgroundData));
}
- if (backgroundMapData.BackgroundMapDataType == BackgroundMapDataType.Wmts)
+ if (backgroundData.BackgroundMapDataType == BackgroundMapDataType.Wmts)
{
- return CreateWmtsBackgroundMapData(backgroundMapData);
+ return CreateWmtsBackgroundMapData(backgroundData);
}
return null;
@@ -57,24 +57,24 @@
/// Updates an existing .
///
/// The to update.
- /// The used
+ /// The used
/// to update the map data.
/// The updated .
/// Thrown when any parameter is null.
- public static void UpdateBackgroundMapData(WmtsMapData mapData, BackgroundMapData backgroundMapData)
+ public static void UpdateBackgroundMapData(WmtsMapData mapData, BackgroundData backgroundData)
{
if (mapData == null)
{
throw new ArgumentNullException(nameof(mapData));
}
- if (backgroundMapData == null)
+ if (backgroundData == null)
{
- throw new ArgumentNullException(nameof(backgroundMapData));
+ throw new ArgumentNullException(nameof(backgroundData));
}
- if (backgroundMapData.BackgroundMapDataType == BackgroundMapDataType.Wmts)
+ if (backgroundData.BackgroundMapDataType == BackgroundMapDataType.Wmts)
{
- WmtsMapData newMapData = CreateWmtsBackgroundMapData(backgroundMapData);
+ WmtsMapData newMapData = CreateWmtsBackgroundMapData(backgroundData);
if (newMapData.IsConfigured)
{
@@ -93,7 +93,7 @@
}
}
- private static WmtsMapData CreateWmtsBackgroundMapData(BackgroundMapData backgroundData)
+ private static WmtsMapData CreateWmtsBackgroundMapData(BackgroundData backgroundData)
{
WmtsMapData mapData = WmtsMapData.CreateUnconnectedMapData();
mapData.Name = backgroundData.Name;
Index: Ringtoets/Common/test/Ringtoets.Common.Data.Test/AssessmentSection/BackgroundDataTest.cs
===================================================================
diff -u
--- Ringtoets/Common/test/Ringtoets.Common.Data.Test/AssessmentSection/BackgroundDataTest.cs (revision 0)
+++ Ringtoets/Common/test/Ringtoets.Common.Data.Test/AssessmentSection/BackgroundDataTest.cs (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -0,0 +1,45 @@
+// 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.
+
+using NUnit.Framework;
+using Ringtoets.Common.Data.AssessmentSection;
+
+namespace Ringtoets.Common.Data.Test.AssessmentSection
+{
+ [TestFixture]
+ public class BackgroundDataTest
+ {
+ [Test]
+ public void Constructor_ExpectedValues()
+ {
+ // Call
+ var backgroundMapData = new BackgroundData();
+
+ // Assert
+ Assert.IsTrue(backgroundMapData.IsVisible);
+ Assert.AreEqual(2, backgroundMapData.Transparency.NumberOfDecimalPlaces);
+ Assert.AreEqual(0, backgroundMapData.Transparency.Value);
+ Assert.AreEqual(BackgroundMapDataType.Wmts, backgroundMapData.BackgroundMapDataType);
+ Assert.IsFalse(backgroundMapData.IsConfigured);
+ CollectionAssert.IsEmpty(backgroundMapData.Parameters);
+ }
+ }
+}
\ No newline at end of file
Fisheye: Tag 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4 refers to a dead (removed) revision in file `Ringtoets/Common/test/Ringtoets.Common.Data.Test/AssessmentSection/BackgroundMapDataTest.cs'.
Fisheye: No comparison available. Pass `N' to diff?
Index: Ringtoets/Common/test/Ringtoets.Common.Data.Test/Ringtoets.Common.Data.Test.csproj
===================================================================
diff -u -r709931efbca2f60911829a07dc275f19b2ad0af0 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Common/test/Ringtoets.Common.Data.Test/Ringtoets.Common.Data.Test.csproj (.../Ringtoets.Common.Data.Test.csproj) (revision 709931efbca2f60911829a07dc275f19b2ad0af0)
+++ Ringtoets/Common/test/Ringtoets.Common.Data.Test/Ringtoets.Common.Data.Test.csproj (.../Ringtoets.Common.Data.Test.csproj) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -55,7 +55,7 @@
Properties\GlobalAssembly.cs
-
+
Index: Ringtoets/Common/test/Ringtoets.Common.Data.TestUtil.Test/ObservableTestAssessmentSectionStubTest.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Common/test/Ringtoets.Common.Data.TestUtil.Test/ObservableTestAssessmentSectionStubTest.cs (.../ObservableTestAssessmentSectionStubTest.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/Common/test/Ringtoets.Common.Data.TestUtil.Test/ObservableTestAssessmentSectionStubTest.cs (.../ObservableTestAssessmentSectionStubTest.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -50,8 +50,8 @@
Assert.IsNull(assessmentSection.ReferenceLine);
Assert.IsNull(assessmentSection.HydraulicBoundaryDatabase);
Assert.IsNull(assessmentSection.BackgroundMapData.MapData);
- Assert.IsNotNull(assessmentSection.BackgroundMapData2);
- Assert.AreEqual("Background data", assessmentSection.BackgroundMapData2.Name);
+ Assert.IsNotNull(assessmentSection.BackgroundData);
+ Assert.AreEqual("Background data", assessmentSection.BackgroundData.Name);
Assert.AreEqual(1.0 / 300000.0, assessmentSection.FailureMechanismContribution.Norm);
FailureMechanismContributionItem[] contributionItems = assessmentSection.FailureMechanismContribution.Distribution.ToArray();
Index: Ringtoets/Common/test/Ringtoets.Common.Data.TestUtil/BackgroundMapDataTestDataGenerator.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Common/test/Ringtoets.Common.Data.TestUtil/BackgroundMapDataTestDataGenerator.cs (.../BackgroundMapDataTestDataGenerator.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/Common/test/Ringtoets.Common.Data.TestUtil/BackgroundMapDataTestDataGenerator.cs (.../BackgroundMapDataTestDataGenerator.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -26,9 +26,9 @@
{
public static class BackgroundMapDataTestDataGenerator
{
- public static BackgroundMapData GetWmtsBackgroundMapData(WmtsMapData wmtsMapData)
+ public static BackgroundData GetWmtsBackgroundMapData(WmtsMapData wmtsMapData)
{
- var backgroundMapData = new BackgroundMapData
+ var backgroundMapData = new BackgroundData
{
Name = wmtsMapData.Name,
IsVisible = wmtsMapData.IsVisible,
@@ -47,9 +47,9 @@
return backgroundMapData;
}
- public static BackgroundMapData GetWellKnownBackgroundMapData()
+ public static BackgroundData GetWellKnownBackgroundMapData()
{
- return new BackgroundMapData
+ return new BackgroundData
{
BackgroundMapDataType = BackgroundMapDataType.WellKnown
};
Index: Ringtoets/Common/test/Ringtoets.Common.Data.TestUtil/ObservableTestAssessmentSectionStub.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Common/test/Ringtoets.Common.Data.TestUtil/ObservableTestAssessmentSectionStub.cs (.../ObservableTestAssessmentSectionStub.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/Common/test/Ringtoets.Common.Data.TestUtil/ObservableTestAssessmentSectionStub.cs (.../ObservableTestAssessmentSectionStub.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -41,7 +41,7 @@
{
FailureMechanismContribution = new FailureMechanismContribution(Enumerable.Empty(), 0, 1.0 / 300000);
BackgroundMapData = new BackgroundMapDataContainer();
- BackgroundMapData2 = new BackgroundMapData
+ BackgroundData = new BackgroundData
{
Name = "Background data"
};
@@ -55,7 +55,7 @@
public FailureMechanismContribution FailureMechanismContribution { get; }
public HydraulicBoundaryDatabase HydraulicBoundaryDatabase { get; set; }
public BackgroundMapDataContainer BackgroundMapData { get; }
- public BackgroundMapData BackgroundMapData2 { get; }
+ public BackgroundData BackgroundData { get; }
public IEnumerable GetFailureMechanisms()
{
Index: Ringtoets/Common/test/Ringtoets.Common.Forms.Test/Views/FailureMechanismViewTest.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Common/test/Ringtoets.Common.Forms.Test/Views/FailureMechanismViewTest.cs (.../FailureMechanismViewTest.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/Common/test/Ringtoets.Common.Forms.Test/Views/FailureMechanismViewTest.cs (.../FailureMechanismViewTest.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -107,7 +107,7 @@
view.Data = failureMechanismContext;
// Assert
- WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(assessmentSection.BackgroundMapData2);
+ WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(assessmentSection.BackgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
@@ -167,7 +167,7 @@
Assert.AreSame(failureMechanismContext, view.Data);
AssertEmptyMapData(view.Map.Data);
WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(
- assessmentSection.BackgroundMapData2);
+ assessmentSection.BackgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
@@ -375,19 +375,19 @@
var assessmentSection = new ObservableTestAssessmentSectionStub();
view.Data = new FailureMechanismContext(new TestFailureMechanism(), assessmentSection);
- BackgroundMapData backgroundMapData = assessmentSection.BackgroundMapData2;
+ BackgroundData backgroundData = assessmentSection.BackgroundData;
- backgroundMapData.Name = "some Name";
- backgroundMapData.Parameters["SourceCapabilitiesUrl"] = "some URL";
- backgroundMapData.Parameters["SelectedCapabilityIdentifier"] = "some Identifier";
- backgroundMapData.Parameters["PreferredFormat"] = "image/some Format";
- backgroundMapData.IsConfigured = true;
+ backgroundData.Name = "some Name";
+ backgroundData.Parameters["SourceCapabilitiesUrl"] = "some URL";
+ backgroundData.Parameters["SelectedCapabilityIdentifier"] = "some Identifier";
+ backgroundData.Parameters["PreferredFormat"] = "image/some Format";
+ backgroundData.IsConfigured = true;
// When
- backgroundMapData.NotifyObservers();
+ backgroundData.NotifyObservers();
// Then
- WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundMapData);
+ WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
Index: Ringtoets/Common/test/Ringtoets.Common.Forms.Test/Views/RingtoetsBackgroundMapDataFactoryTest.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Common/test/Ringtoets.Common.Forms.Test/Views/RingtoetsBackgroundMapDataFactoryTest.cs (.../RingtoetsBackgroundMapDataFactoryTest.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/Common/test/Ringtoets.Common.Forms.Test/Views/RingtoetsBackgroundMapDataFactoryTest.cs (.../RingtoetsBackgroundMapDataFactoryTest.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -47,10 +47,10 @@
public void CreateBackgroundMapData_BackgroundMapDataTypeWellKnown_ReturnNull()
{
// Setup
- BackgroundMapData backgroundMapData = BackgroundMapDataTestDataGenerator.GetWellKnownBackgroundMapData();
+ BackgroundData backgroundData = BackgroundMapDataTestDataGenerator.GetWellKnownBackgroundMapData();
// Call
- WmtsMapData mapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundMapData);
+ WmtsMapData mapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundData);
// Assert
Assert.IsNull(mapData);
@@ -61,10 +61,10 @@
{
// Setup
WmtsMapData wmtsMapData = WmtsMapData.CreateDefaultPdokMapData();
- BackgroundMapData backgroundMapData = BackgroundMapDataTestDataGenerator.GetWmtsBackgroundMapData(wmtsMapData);
+ BackgroundData backgroundData = BackgroundMapDataTestDataGenerator.GetWmtsBackgroundMapData(wmtsMapData);
// Call
- WmtsMapData mapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundMapData);
+ WmtsMapData mapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundData);
// Assert
Assert.AreEqual(wmtsMapData.Name, mapData.Name);
@@ -81,10 +81,10 @@
{
// Setup
WmtsMapData wmtsMapData = WmtsMapData.CreateUnconnectedMapData();
- BackgroundMapData backgroundMapData = BackgroundMapDataTestDataGenerator.GetWmtsBackgroundMapData(wmtsMapData);
+ BackgroundData backgroundData = BackgroundMapDataTestDataGenerator.GetWmtsBackgroundMapData(wmtsMapData);
// Call
- WmtsMapData mapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundMapData);
+ WmtsMapData mapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundData);
// Assert
Assert.AreEqual(wmtsMapData.Name, mapData.Name);
@@ -100,7 +100,7 @@
public void UpdateBackgroundMapData_WmtsMapDataNull_ThrowArgumentNullException()
{
// Call
- TestDelegate test = () => RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(null, new BackgroundMapData());
+ TestDelegate test = () => RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(null, new BackgroundData());
// Assert
var exception = Assert.Throws(test);
@@ -123,18 +123,18 @@
{
// Setup
WmtsMapData wmtsMapData = WmtsMapData.CreateDefaultPdokMapData();
- BackgroundMapData backgroundMapData = BackgroundMapDataTestDataGenerator.GetWellKnownBackgroundMapData();
+ BackgroundData backgroundData = BackgroundMapDataTestDataGenerator.GetWellKnownBackgroundMapData();
string originalName = wmtsMapData.Name;
bool originalVisibility = wmtsMapData.IsVisible;
RoundedDouble originalTransparancy = wmtsMapData.Transparency;
- backgroundMapData.Name = "new name";
- backgroundMapData.IsVisible = true;
- backgroundMapData.Transparency = (RoundedDouble) 0.4;
+ backgroundData.Name = "new name";
+ backgroundData.IsVisible = true;
+ backgroundData.Transparency = (RoundedDouble) 0.4;
// Call
- RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(wmtsMapData, backgroundMapData);
+ RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(wmtsMapData, backgroundData);
// Assert
Assert.AreEqual(originalName, wmtsMapData.Name);
@@ -147,18 +147,18 @@
{
// Setup
WmtsMapData wmtsMapData = WmtsMapData.CreateDefaultPdokMapData();
- BackgroundMapData backgroundMapData = BackgroundMapDataTestDataGenerator.GetWmtsBackgroundMapData(wmtsMapData);
+ BackgroundData backgroundData = BackgroundMapDataTestDataGenerator.GetWmtsBackgroundMapData(wmtsMapData);
- string originalSourceCapabilitiesUrl = backgroundMapData.Parameters["SourceCapabilitiesUrl"];
- string originalSelectedCapabilityIdentifier = backgroundMapData.Parameters["SelectedCapabilityIdentifier"];
- string originalPreferredFormat = backgroundMapData.Parameters["PreferredFormat"];
+ string originalSourceCapabilitiesUrl = backgroundData.Parameters["SourceCapabilitiesUrl"];
+ string originalSelectedCapabilityIdentifier = backgroundData.Parameters["SelectedCapabilityIdentifier"];
+ string originalPreferredFormat = backgroundData.Parameters["PreferredFormat"];
- backgroundMapData.Parameters["SourceCapabilitiesUrl"] = "some/url";
- backgroundMapData.Parameters["SelectedCapabilityIdentifier"] = "identifier";
- backgroundMapData.Parameters["PreferredFormat"] = "image/format";
+ backgroundData.Parameters["SourceCapabilitiesUrl"] = "some/url";
+ backgroundData.Parameters["SelectedCapabilityIdentifier"] = "identifier";
+ backgroundData.Parameters["PreferredFormat"] = "image/format";
// Call
- RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(wmtsMapData, backgroundMapData);
+ RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(wmtsMapData, backgroundData);
// Assert
Assert.AreNotEqual(originalSourceCapabilitiesUrl, wmtsMapData.SourceCapabilitiesUrl);
@@ -171,16 +171,16 @@
{
// Given
WmtsMapData wmtsMapData = WmtsMapData.CreateDefaultPdokMapData();
- BackgroundMapData backgroundMapData = BackgroundMapDataTestDataGenerator.GetWmtsBackgroundMapData(wmtsMapData);
+ BackgroundData backgroundData = BackgroundMapDataTestDataGenerator.GetWmtsBackgroundMapData(wmtsMapData);
// Precondition
Assert.IsNotNull(wmtsMapData.SourceCapabilitiesUrl);
Assert.IsNotNull(wmtsMapData.SelectedCapabilityIdentifier);
Assert.IsNotNull(wmtsMapData.PreferredFormat);
// When
- backgroundMapData.IsConfigured = false;
- RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(wmtsMapData, backgroundMapData);
+ backgroundData.IsConfigured = false;
+ RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(wmtsMapData, backgroundData);
// Then
Assert.IsNull(wmtsMapData.SourceCapabilitiesUrl);
Index: Ringtoets/DuneErosion/src/Ringtoets.DuneErosion.Forms/Views/DuneErosionFailureMechanismView.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/DuneErosion/src/Ringtoets.DuneErosion.Forms/Views/DuneErosionFailureMechanismView.cs (.../DuneErosionFailureMechanismView.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/DuneErosion/src/Ringtoets.DuneErosion.Forms/Views/DuneErosionFailureMechanismView.cs (.../DuneErosionFailureMechanismView.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -109,11 +109,11 @@
mapDataCollection.Name = data.WrappedData.Name;
duneLocationsObserver.Observable = data.WrappedData.DuneLocations;
- backgroundMapDataObserver.Observable = data.Parent.BackgroundMapData2;
+ backgroundMapDataObserver.Observable = data.Parent.BackgroundData;
SetMapDataFeatures();
- backgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(data.Parent.BackgroundMapData2);
+ backgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(data.Parent.BackgroundData);
Map.Data = mapDataCollection;
Map.BackgroundMapData = backgroundMapData;
@@ -144,7 +144,7 @@
private void UpdateBackgroundMapData()
{
- RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(backgroundMapData, data.Parent.BackgroundMapData2);
+ RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(backgroundMapData, data.Parent.BackgroundData);
backgroundMapData.NotifyObservers();
}
Index: Ringtoets/DuneErosion/test/Ringtoets.DuneErosion.Forms.Test/Views/DuneErosionFailureMechanismViewTest.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/DuneErosion/test/Ringtoets.DuneErosion.Forms.Test/Views/DuneErosionFailureMechanismViewTest.cs (.../DuneErosionFailureMechanismViewTest.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/DuneErosion/test/Ringtoets.DuneErosion.Forms.Test/Views/DuneErosionFailureMechanismViewTest.cs (.../DuneErosionFailureMechanismViewTest.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -127,7 +127,7 @@
view.Data = failureMechanismContext;
// Assert
- WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(assessmentSection.BackgroundMapData2);
+ WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(assessmentSection.BackgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
@@ -174,7 +174,7 @@
Assert.AreSame(failureMechanismContext, view.Data);
AssertEmptyMapData(view.Map.Data);
WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(
- assessmentSection.BackgroundMapData2);
+ assessmentSection.BackgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
@@ -353,19 +353,19 @@
var assessmentSection = new ObservableTestAssessmentSectionStub();
view.Data = new DuneErosionFailureMechanismContext(new DuneErosionFailureMechanism(), assessmentSection);
- BackgroundMapData backgroundMapData = assessmentSection.BackgroundMapData2;
+ BackgroundData backgroundData = assessmentSection.BackgroundData;
- backgroundMapData.Name = "some Name";
- backgroundMapData.Parameters["SourceCapabilitiesUrl"] = "some URL";
- backgroundMapData.Parameters["SelectedCapabilityIdentifier"] = "some Identifier";
- backgroundMapData.Parameters["PreferredFormat"] = "image/some Format";
- backgroundMapData.IsConfigured = true;
+ backgroundData.Name = "some Name";
+ backgroundData.Parameters["SourceCapabilitiesUrl"] = "some URL";
+ backgroundData.Parameters["SelectedCapabilityIdentifier"] = "some Identifier";
+ backgroundData.Parameters["PreferredFormat"] = "image/some Format";
+ backgroundData.IsConfigured = true;
// When
- backgroundMapData.NotifyObservers();
+ backgroundData.NotifyObservers();
// Then
- WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundMapData);
+ WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
Index: Ringtoets/GrassCoverErosionInwards/src/Ringtoets.GrassCoverErosionInwards.Forms/Views/GrassCoverErosionInwardsFailureMechanismView.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/GrassCoverErosionInwards/src/Ringtoets.GrassCoverErosionInwards.Forms/Views/GrassCoverErosionInwardsFailureMechanismView.cs (.../GrassCoverErosionInwardsFailureMechanismView.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/GrassCoverErosionInwards/src/Ringtoets.GrassCoverErosionInwards.Forms/Views/GrassCoverErosionInwardsFailureMechanismView.cs (.../GrassCoverErosionInwardsFailureMechanismView.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -147,11 +147,11 @@
calculationGroupObserver.Observable = data.WrappedData.CalculationsGroup;
calculationObserver.Observable = data.WrappedData.CalculationsGroup;
- backgroundMapDataObserver.Observable = data.Parent.BackgroundMapData2;
+ backgroundMapDataObserver.Observable = data.Parent.BackgroundData;
SetMapDataFeatures();
- backgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(data.Parent.BackgroundMapData2);
+ backgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(data.Parent.BackgroundData);
Map.Data = mapDataCollection;
Map.BackgroundMapData = backgroundMapData;
@@ -186,7 +186,7 @@
private void UpdateBackgroundMapData()
{
- RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(backgroundMapData, data.Parent.BackgroundMapData2);
+ RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(backgroundMapData, data.Parent.BackgroundData);
backgroundMapData.NotifyObservers();
}
Index: Ringtoets/GrassCoverErosionInwards/test/Ringtoets.GrassCoverErosionInwards.Forms.Test/Views/GrassCoverErosionInwardsFailureMechanismViewTest.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/GrassCoverErosionInwards/test/Ringtoets.GrassCoverErosionInwards.Forms.Test/Views/GrassCoverErosionInwardsFailureMechanismViewTest.cs (.../GrassCoverErosionInwardsFailureMechanismViewTest.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/GrassCoverErosionInwards/test/Ringtoets.GrassCoverErosionInwards.Forms.Test/Views/GrassCoverErosionInwardsFailureMechanismViewTest.cs (.../GrassCoverErosionInwardsFailureMechanismViewTest.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -128,7 +128,7 @@
view.Data = failureMechanismContext;
// Assert
- WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(assessmentSection.BackgroundMapData2);
+ WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(assessmentSection.BackgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
@@ -175,7 +175,7 @@
Assert.AreSame(failureMechanismContext, view.Data);
AssertEmptyMapData(view.Map.Data);
WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(
- assessmentSection.BackgroundMapData2);
+ assessmentSection.BackgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
@@ -421,19 +421,19 @@
var assessmentSection = new ObservableTestAssessmentSectionStub();
view.Data = new GrassCoverErosionInwardsFailureMechanismContext(new GrassCoverErosionInwardsFailureMechanism(), assessmentSection);
- BackgroundMapData backgroundMapData = assessmentSection.BackgroundMapData2;
+ BackgroundData backgroundData = assessmentSection.BackgroundData;
- backgroundMapData.Name = "some Name";
- backgroundMapData.Parameters["SourceCapabilitiesUrl"] = "some URL";
- backgroundMapData.Parameters["SelectedCapabilityIdentifier"] = "some Identifier";
- backgroundMapData.Parameters["PreferredFormat"] = "image/some Format";
- backgroundMapData.IsConfigured = true;
+ backgroundData.Name = "some Name";
+ backgroundData.Parameters["SourceCapabilitiesUrl"] = "some URL";
+ backgroundData.Parameters["SelectedCapabilityIdentifier"] = "some Identifier";
+ backgroundData.Parameters["PreferredFormat"] = "image/some Format";
+ backgroundData.IsConfigured = true;
// When
- backgroundMapData.NotifyObservers();
+ backgroundData.NotifyObservers();
// Then
- WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundMapData);
+ WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
Index: Ringtoets/GrassCoverErosionOutwards/src/Ringtoets.GrassCoverErosionOutwards.Forms/Views/GrassCoverErosionOutwardsFailureMechanismView.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/GrassCoverErosionOutwards/src/Ringtoets.GrassCoverErosionOutwards.Forms/Views/GrassCoverErosionOutwardsFailureMechanismView.cs (.../GrassCoverErosionOutwardsFailureMechanismView.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/GrassCoverErosionOutwards/src/Ringtoets.GrassCoverErosionOutwards.Forms/Views/GrassCoverErosionOutwardsFailureMechanismView.cs (.../GrassCoverErosionOutwardsFailureMechanismView.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -137,11 +137,11 @@
calculationGroupObserver.Observable = data.WrappedData.WaveConditionsCalculationGroup;
calculationObserver.Observable = data.WrappedData.WaveConditionsCalculationGroup;
- backgroundMapDataObserver.Observable = data.Parent.BackgroundMapData2;
+ backgroundMapDataObserver.Observable = data.Parent.BackgroundData;
SetMapDataFeatures();
- backgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(data.Parent.BackgroundMapData2);
+ backgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(data.Parent.BackgroundData);
Map.Data = mapDataCollection;
Map.BackgroundMapData = backgroundMapData;
@@ -176,7 +176,7 @@
private void UpdateBackgroundMapData()
{
- RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(backgroundMapData, data.Parent.BackgroundMapData2);
+ RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(backgroundMapData, data.Parent.BackgroundData);
backgroundMapData.NotifyObservers();
}
Index: Ringtoets/GrassCoverErosionOutwards/test/Ringtoets.GrassCoverErosionOutwards.Forms.Test/Views/GrassCoverErosionOutwardsFailureMechanismViewTest.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/GrassCoverErosionOutwards/test/Ringtoets.GrassCoverErosionOutwards.Forms.Test/Views/GrassCoverErosionOutwardsFailureMechanismViewTest.cs (.../GrassCoverErosionOutwardsFailureMechanismViewTest.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/GrassCoverErosionOutwards/test/Ringtoets.GrassCoverErosionOutwards.Forms.Test/Views/GrassCoverErosionOutwardsFailureMechanismViewTest.cs (.../GrassCoverErosionOutwardsFailureMechanismViewTest.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -127,7 +127,7 @@
view.Data = failureMechanismContext;
// Assert
- WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(assessmentSection.BackgroundMapData2);
+ WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(assessmentSection.BackgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
@@ -176,7 +176,7 @@
Assert.AreSame(failureMechanismContext, view.Data);
AssertEmptyMapData(view.Map.Data);
WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(
- assessmentSection.BackgroundMapData2);
+ assessmentSection.BackgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
@@ -315,19 +315,19 @@
var assessmentSection = new ObservableTestAssessmentSectionStub();
view.Data = new GrassCoverErosionOutwardsFailureMechanismContext(new GrassCoverErosionOutwardsFailureMechanism(), assessmentSection);
- BackgroundMapData backgroundMapData = assessmentSection.BackgroundMapData2;
+ BackgroundData backgroundData = assessmentSection.BackgroundData;
- backgroundMapData.Name = "some Name";
- backgroundMapData.Parameters["SourceCapabilitiesUrl"] = "some URL";
- backgroundMapData.Parameters["SelectedCapabilityIdentifier"] = "some Identifier";
- backgroundMapData.Parameters["PreferredFormat"] = "image/some Format";
- backgroundMapData.IsConfigured = true;
+ backgroundData.Name = "some Name";
+ backgroundData.Parameters["SourceCapabilitiesUrl"] = "some URL";
+ backgroundData.Parameters["SelectedCapabilityIdentifier"] = "some Identifier";
+ backgroundData.Parameters["PreferredFormat"] = "image/some Format";
+ backgroundData.IsConfigured = true;
// When
- backgroundMapData.NotifyObservers();
+ backgroundData.NotifyObservers();
// Then
- WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundMapData);
+ WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
Index: Ringtoets/HeightStructures/src/Ringtoets.HeightStructures.Forms/Views/HeightStructuresFailureMechanismView.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/HeightStructures/src/Ringtoets.HeightStructures.Forms/Views/HeightStructuresFailureMechanismView.cs (.../HeightStructuresFailureMechanismView.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/HeightStructures/src/Ringtoets.HeightStructures.Forms/Views/HeightStructuresFailureMechanismView.cs (.../HeightStructuresFailureMechanismView.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -153,11 +153,11 @@
calculationGroupObserver.Observable = data.WrappedData.CalculationsGroup;
calculationObserver.Observable = data.WrappedData.CalculationsGroup;
- backgroundMapDataObserver.Observable = data.Parent.BackgroundMapData2;
+ backgroundMapDataObserver.Observable = data.Parent.BackgroundData;
SetMapDataFeatures();
- backgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(data.Parent.BackgroundMapData2);
+ backgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(data.Parent.BackgroundData);
Map.Data = mapDataCollection;
Map.BackgroundMapData = backgroundMapData;
@@ -193,7 +193,7 @@
private void UpdateBackgroundMapData()
{
- RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(backgroundMapData, data.Parent.BackgroundMapData2);
+ RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(backgroundMapData, data.Parent.BackgroundData);
backgroundMapData.NotifyObservers();
}
Index: Ringtoets/HeightStructures/test/Ringtoets.HeightStructures.Forms.Test/Views/HeightStructuresFailureMechanismViewTest.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/HeightStructures/test/Ringtoets.HeightStructures.Forms.Test/Views/HeightStructuresFailureMechanismViewTest.cs (.../HeightStructuresFailureMechanismViewTest.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/HeightStructures/test/Ringtoets.HeightStructures.Forms.Test/Views/HeightStructuresFailureMechanismViewTest.cs (.../HeightStructuresFailureMechanismViewTest.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -132,7 +132,7 @@
view.Data = failureMechanismContext;
// Assert
- WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(assessmentSection.BackgroundMapData2);
+ WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(assessmentSection.BackgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
@@ -181,7 +181,7 @@
Assert.AreSame(failureMechanismContext, view.Data);
AssertEmptyMapData(view.Map.Data);
WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(
- assessmentSection.BackgroundMapData2);
+ assessmentSection.BackgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
@@ -431,19 +431,19 @@
var assessmentSection = new ObservableTestAssessmentSectionStub();
view.Data = new HeightStructuresFailureMechanismContext(new HeightStructuresFailureMechanism(), assessmentSection);
- BackgroundMapData backgroundMapData = assessmentSection.BackgroundMapData2;
+ BackgroundData backgroundData = assessmentSection.BackgroundData;
- backgroundMapData.Name = "some Name";
- backgroundMapData.Parameters["SourceCapabilitiesUrl"] = "some URL";
- backgroundMapData.Parameters["SelectedCapabilityIdentifier"] = "some Identifier";
- backgroundMapData.Parameters["PreferredFormat"] = "image/some Format";
- backgroundMapData.IsConfigured = true;
+ backgroundData.Name = "some Name";
+ backgroundData.Parameters["SourceCapabilitiesUrl"] = "some URL";
+ backgroundData.Parameters["SelectedCapabilityIdentifier"] = "some Identifier";
+ backgroundData.Parameters["PreferredFormat"] = "image/some Format";
+ backgroundData.IsConfigured = true;
// When
- backgroundMapData.NotifyObservers();
+ backgroundData.NotifyObservers();
// Then
- WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundMapData);
+ WmtsMapData expectedWmtsBackgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundData);
MapDataTestHelper.AssertWmtsMapData(expectedWmtsBackgroundMapData, view.Map.BackgroundMapData);
}
}
Index: Ringtoets/Integration/src/Ringtoets.Integration.Data/AssessmentSection.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Integration/src/Ringtoets.Integration.Data/AssessmentSection.cs (.../AssessmentSection.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/Integration/src/Ringtoets.Integration.Data/AssessmentSection.cs (.../AssessmentSection.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -69,7 +69,7 @@
MapData = mapData
};
- BackgroundMapData2 = new BackgroundMapData
+ BackgroundData = new BackgroundData
{
IsVisible = mapData.IsVisible,
Transparency = mapData.Transparency,
@@ -221,7 +221,7 @@
public BackgroundMapDataContainer BackgroundMapData { get; }
- public BackgroundMapData BackgroundMapData2 { get; }
+ public BackgroundData BackgroundData { get; }
public IEnumerable GetFailureMechanisms()
{
Index: Ringtoets/Integration/src/Ringtoets.Integration.Forms/PropertyClasses/BackgroundDataProperties.cs
===================================================================
diff -u
--- Ringtoets/Integration/src/Ringtoets.Integration.Forms/PropertyClasses/BackgroundDataProperties.cs (revision 0)
+++ Ringtoets/Integration/src/Ringtoets.Integration.Forms/PropertyClasses/BackgroundDataProperties.cs (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -0,0 +1,171 @@
+// 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.
+
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using Core.Common.Base.Data;
+using Core.Common.Gui.Attributes;
+using Core.Common.Gui.PropertyBag;
+using Core.Common.Utils.Attributes;
+using Ringtoets.Common.Data.AssessmentSection;
+using Ringtoets.Integration.Forms.Properties;
+using RingtoetsCommonFormsResources = Ringtoets.Common.Forms.Properties.Resources;
+using GisFormsResources = Core.Components.Gis.Forms.Properties.Resources;
+
+namespace Ringtoets.Integration.Forms.PropertyClasses
+{
+ ///
+ /// ViewModel of the for properties panel.
+ ///
+ public class BackgroundDataProperties : ObjectProperties
+ {
+ ///
+ /// Creates a new instance of .
+ ///
+ /// The data for which the properties are shown.
+ /// Thrown when
+ /// is null.
+ public BackgroundDataProperties(BackgroundData backgroundData)
+ {
+ if (backgroundData == null)
+ {
+ throw new ArgumentNullException(nameof(backgroundData));
+ }
+
+ Data = backgroundData;
+ }
+
+ [ResourcesCategory(typeof(RingtoetsCommonFormsResources), nameof(RingtoetsCommonFormsResources.Categories_General))]
+ [ResourcesDisplayName(typeof(Resources), nameof(Resources.BackgroundMapDataContainerProperties_Name_DisplayName))]
+ [ResourcesDescription(typeof(Resources), nameof(Resources.BackgroundMapDataContainerProperties_Name_Description))]
+ public string Name
+ {
+ get
+ {
+ return data.IsConfigured ? data.Name : string.Empty;
+ }
+ }
+
+ [ResourcesCategory(typeof(RingtoetsCommonFormsResources), nameof(RingtoetsCommonFormsResources.Categories_General))]
+ [ResourcesDisplayName(typeof(Resources), nameof(Resources.BackgroundMapDataContainerProperties_Transparency_DisplayName))]
+ [ResourcesDescription(typeof(Resources), nameof(Resources.BackgroundMapDataContainerProperties_Transparency_Description))]
+ public RoundedDouble Transparency
+ {
+ get
+ {
+ return data.Transparency;
+ }
+ set
+ {
+ data.Transparency = value;
+ data.NotifyObservers();
+ }
+ }
+
+ [ResourcesCategory(typeof(RingtoetsCommonFormsResources), nameof(RingtoetsCommonFormsResources.Categories_General))]
+ [ResourcesDisplayName(typeof(Resources), nameof(Resources.BackgroundMapDataContainerProperties_IsVisible_DisplayName))]
+ [ResourcesDescription(typeof(Resources), nameof(Resources.BackgroundMapDataContainerProperties_IsVisible_Description))]
+ public bool IsVisible
+ {
+ get
+ {
+ return data.IsVisible;
+ }
+ set
+ {
+ data.IsVisible = value;
+ data.NotifyObservers();
+ }
+ }
+
+ [DynamicVisibleValidationMethod]
+ public bool DynamicVisibleValidationMethod(string propertyName)
+ {
+ return data.IsConfigured
+ && data.BackgroundMapDataType == BackgroundMapDataType.Wmts
+ && WmtsProperties.Contains(propertyName);
+ }
+
+ #region Wmts MapData
+
+ [DynamicVisible]
+ [ResourcesCategory(typeof(Resources), nameof(Resources.BackgroundWmtsMapDataContainerProperties_WMTS_Category))]
+ [ResourcesDisplayName(typeof(Resources), nameof(Resources.BackgroundWmtsMapDataContainerProperties_Url_DisplayName))]
+ [ResourcesDescription(typeof(Resources), nameof(Resources.BackgroundWmtsMapDataContainerProperties_Url_Description))]
+ public string SourceCapabilitiesUrl
+ {
+ get
+ {
+ return GetBackgroundMapDataParameter(data, nameof(SourceCapabilitiesUrl));
+ }
+ }
+
+ [DynamicVisible]
+ [ResourcesCategory(typeof(Resources), nameof(Resources.BackgroundWmtsMapDataContainerProperties_WMTS_Category))]
+ [ResourcesDisplayName(typeof(GisFormsResources), nameof(GisFormsResources.WmtsCapability_MapLayer_Id))]
+ [ResourcesDescription(typeof(Resources), nameof(Resources.BackgroundWmtsMapDataContainerProperties_SelectedCapabilityIdentifier_Description))]
+ public string SelectedCapabilityIdentifier
+ {
+ get
+ {
+ return GetBackgroundMapDataParameter(data, nameof(SelectedCapabilityIdentifier));
+ }
+ }
+
+ [DynamicVisible]
+ [ResourcesCategory(typeof(Resources), nameof(Resources.BackgroundWmtsMapDataContainerProperties_WMTS_Category))]
+ [ResourcesDisplayName(typeof(GisFormsResources), nameof(GisFormsResources.WmtsCapability_MapLayer_Format))]
+ [ResourcesDescription(typeof(Resources), nameof(Resources.BackgroundWmtsMapDataContainerProperties_PreferredFormat_Description))]
+ public string PreferredFormat
+ {
+ get
+ {
+ return GetBackgroundMapDataParameter(data, nameof(PreferredFormat));
+ }
+ }
+
+ private string GetBackgroundMapDataParameter(BackgroundData backgroundData, string parameterName)
+ {
+ if (backgroundData.IsConfigured
+ && backgroundData.BackgroundMapDataType == BackgroundMapDataType.Wmts
+ && WmtsProperties.Contains(parameterName)
+ && backgroundData.Parameters.ContainsKey(parameterName))
+ {
+ return backgroundData.Parameters[parameterName];
+ }
+
+ return string.Empty;
+ }
+
+ private IEnumerable WmtsProperties
+ {
+ get
+ {
+ yield return nameof(SourceCapabilitiesUrl);
+ yield return nameof(SelectedCapabilityIdentifier);
+ yield return nameof(PreferredFormat);
+ }
+ }
+
+ #endregion
+ }
+}
\ No newline at end of file
Fisheye: Tag 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4 refers to a dead (removed) revision in file `Ringtoets/Integration/src/Ringtoets.Integration.Forms/PropertyClasses/BackgroundMapDataProperties.cs'.
Fisheye: No comparison available. Pass `N' to diff?
Index: Ringtoets/Integration/src/Ringtoets.Integration.Forms/Ringtoets.Integration.Forms.csproj
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Integration/src/Ringtoets.Integration.Forms/Ringtoets.Integration.Forms.csproj (.../Ringtoets.Integration.Forms.csproj) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/Integration/src/Ringtoets.Integration.Forms/Ringtoets.Integration.Forms.csproj (.../Ringtoets.Integration.Forms.csproj) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -60,7 +60,7 @@
-
+
Index: Ringtoets/Integration/src/Ringtoets.Integration.Forms/Views/AssessmentSectionView.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Integration/src/Ringtoets.Integration.Forms/Views/AssessmentSectionView.cs (.../AssessmentSectionView.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/Integration/src/Ringtoets.Integration.Forms/Views/AssessmentSectionView.cs (.../AssessmentSectionView.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -85,7 +85,7 @@
assessmentSectionObserver.Observable = data;
hydraulicBoundaryDatabaseObserver.Observable = data?.HydraulicBoundaryDatabase;
- backgroundMapDataObserver.Observable = data?.BackgroundMapData2;
+ backgroundMapDataObserver.Observable = data?.BackgroundData;
if (data == null)
{
@@ -96,7 +96,7 @@
{
SetMapDataFeatures();
- backgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(data.BackgroundMapData2);
+ backgroundMapData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(data.BackgroundData);
Map.Data = mapDataCollection;
Map.BackgroundMapData = backgroundMapData;
@@ -126,7 +126,7 @@
private void UpdateBackgroundMapData()
{
- RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(backgroundMapData, data.BackgroundMapData2);
+ RingtoetsBackgroundMapDataFactory.UpdateBackgroundMapData(backgroundMapData, data.BackgroundData);
backgroundMapData.NotifyObservers();
}
Index: Ringtoets/Integration/src/Ringtoets.Integration.Plugin/Properties/Resources.Designer.cs
===================================================================
diff -u -r70952faba3713dc603266d3a2bc9c00eb4397caf -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Integration/src/Ringtoets.Integration.Plugin/Properties/Resources.Designer.cs (.../Resources.Designer.cs) (revision 70952faba3713dc603266d3a2bc9c00eb4397caf)
+++ Ringtoets/Integration/src/Ringtoets.Integration.Plugin/Properties/Resources.Designer.cs (.../Resources.Designer.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -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.42000
@@ -106,18 +85,18 @@
///
/// Looks up a localized string similar to Selecteren....
///
- public static string BackgroundMapData_SelectMapData {
+ public static string BackgroundData_SelectMapData {
get {
- return ResourceManager.GetString("BackgroundMapData_SelectMapData", resourceCulture);
+ return ResourceManager.GetString("BackgroundData_SelectMapData", resourceCulture);
}
}
///
/// Looks up a localized string similar to Selecteer een achtergrondkaart..
///
- public static string BackgroundMapData_SelectMapData_Tooltip {
+ public static string BackgroundData_SelectMapData_Tooltip {
get {
- return ResourceManager.GetString("BackgroundMapData_SelectMapData_Tooltip", resourceCulture);
+ return ResourceManager.GetString("BackgroundData_SelectMapData_Tooltip", resourceCulture);
}
}
@@ -222,9 +201,9 @@
///
/// Looks up a localized string similar to Achtergrondkaart.
///
- public static string RingtoetsPlugin_BackgroundMapDataContext_Text {
+ public static string RingtoetsPlugin_BackgroundDataContext_Text {
get {
- return ResourceManager.GetString("RingtoetsPlugin_BackgroundMapDataContext_Text", resourceCulture);
+ return ResourceManager.GetString("RingtoetsPlugin_BackgroundDataContext_Text", resourceCulture);
}
}
Index: Ringtoets/Integration/src/Ringtoets.Integration.Plugin/Properties/Resources.resx
===================================================================
diff -u -r70952faba3713dc603266d3a2bc9c00eb4397caf -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Integration/src/Ringtoets.Integration.Plugin/Properties/Resources.resx (.../Resources.resx) (revision 70952faba3713dc603266d3a2bc9c00eb4397caf)
+++ Ringtoets/Integration/src/Ringtoets.Integration.Plugin/Properties/Resources.resx (.../Resources.resx) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -158,7 +158,7 @@
Weet u zeker dat u wilt doorgaan?
-
+
Achtergrondkaart
@@ -169,10 +169,10 @@
Weet u zeker dat u wilt doorgaan?
-
+
Selecteren...
-
+
Selecteer een achtergrondkaart.
\ No newline at end of file
Index: Ringtoets/Integration/src/Ringtoets.Integration.Plugin/RingtoetsPlugin.cs
===================================================================
diff -u -rb519fc798c63691f04bb8008b562a94ed9232d51 -r7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4
--- Ringtoets/Integration/src/Ringtoets.Integration.Plugin/RingtoetsPlugin.cs (.../RingtoetsPlugin.cs) (revision b519fc798c63691f04bb8008b562a94ed9232d51)
+++ Ringtoets/Integration/src/Ringtoets.Integration.Plugin/RingtoetsPlugin.cs (.../RingtoetsPlugin.cs) (revision 7a4f8ff71ae5f81177fe5ff9cd78fdc7f24c69f4)
@@ -36,7 +36,6 @@
using Core.Common.Gui.Plugin;
using Core.Common.IO.Exceptions;
using Core.Common.Utils.Extensions;
-using Core.Components.Gis;
using Core.Components.Gis.Data;
using log4net;
using Ringtoets.ClosingStructures.Data;
@@ -268,15 +267,15 @@
}
///
- /// Returns all instances provided for data of .
+ /// Returns all instances provided for data of .
///
public override IEnumerable GetPropertyInfos()
{
yield return new PropertyInfo();
yield return new PropertyInfo();
- yield return new PropertyInfo
+ yield return new PropertyInfo
{
- CreateInstance = container => new BackgroundMapDataProperties(container)
+ CreateInstance = container => new BackgroundDataProperties(container)
};
yield return new PropertyInfo();
yield return new PropertyInfo
@@ -514,11 +513,11 @@
OnNodeRemoved = AssessmentSectionOnNodeRemoved
};
- yield return new TreeNodeInfo
+ yield return new TreeNodeInfo
{
- Text = container => RingtoetsIntegrationPluginResources.RingtoetsPlugin_BackgroundMapDataContext_Text,
+ Text = container => RingtoetsIntegrationPluginResources.RingtoetsPlugin_BackgroundDataContext_Text,
Image = container => RingtoetsFormsResources.Map,
- ContextMenuStrip = BackgroundMapDataMenuStrip,
+ ContextMenuStrip = BackgroundDataMenuStrip,
ForeColor = data => data.IsConfigured ?
Color.FromKnownColor(KnownColor.ControlText) :
Color.FromKnownColor(KnownColor.GrayText)
@@ -883,15 +882,15 @@
}
}
- #region BackgroundMapData treeNodeInfo
+ #region BackgroundData treeNodeInfo
- private ContextMenuStrip BackgroundMapDataMenuStrip(BackgroundMapData nodeData, object parentData, TreeViewControl treeViewControl)
+ private ContextMenuStrip BackgroundDataMenuStrip(BackgroundData nodeData, object parentData, TreeViewControl treeViewControl)
{
var assessmentSection = parentData as IAssessmentSection;
var mapDataItem = new StrictContextMenuItem(
- RingtoetsIntegrationPluginResources.BackgroundMapData_SelectMapData,
- RingtoetsIntegrationPluginResources.BackgroundMapData_SelectMapData_Tooltip,
+ RingtoetsIntegrationPluginResources.BackgroundData_SelectMapData,
+ RingtoetsIntegrationPluginResources.BackgroundData_SelectMapData_Tooltip,
RingtoetsCommonFormsResources.MapsIcon, (sender, args) => { SelectMapData(assessmentSection, nodeData); });
return Gui.Get(nodeData, treeViewControl)
@@ -900,14 +899,14 @@
.Build();
}
- private void SelectMapData(IAssessmentSection assessmentSection, BackgroundMapData backgroundMapData)
+ private void SelectMapData(IAssessmentSection assessmentSection, BackgroundData backgroundData)
{
if (assessmentSection == null)
{
return;
}
- WmtsMapData currentData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundMapData);
+ WmtsMapData currentData = RingtoetsBackgroundMapDataFactory.CreateBackgroundMapData(backgroundData);
using (var dialog = new BackgroundMapDataSelectionDialog(Gui.MainWindow, currentData))
{
if (dialog.ShowDialog() == DialogResult.OK)
@@ -919,27 +918,27 @@
private static void SetSelectedMapData(IAssessmentSection assessmentSection, ImageBasedMapData selectedMapData)
{
- assessmentSection.BackgroundMapData2.Name = string.Empty;
- assessmentSection.BackgroundMapData2.IsVisible = false;
- assessmentSection.BackgroundMapData2.Parameters.Clear();
+ assessmentSection.BackgroundData.Name = string.Empty;
+ assessmentSection.BackgroundData.IsVisible = false;
+ assessmentSection.BackgroundData.Parameters.Clear();
if (selectedMapData != null)
{
selectedMapData.IsVisible = true;
- assessmentSection.BackgroundMapData2.IsVisible = selectedMapData.IsVisible;
- assessmentSection.BackgroundMapData2.IsConfigured = selectedMapData.IsConfigured;
- assessmentSection.BackgroundMapData2.Name = selectedMapData.Name;
+ assessmentSection.BackgroundData.IsVisible = selectedMapData.IsVisible;
+ assessmentSection.BackgroundData.IsConfigured = selectedMapData.IsConfigured;
+ assessmentSection.BackgroundData.Name = selectedMapData.Name;
var selectedWmtsMapData = selectedMapData as WmtsMapData;
if (selectedWmtsMapData != null)
{
- assessmentSection.BackgroundMapData2.Parameters["SourceCapabilitiesUrl"] = selectedWmtsMapData.SourceCapabilitiesUrl;
- assessmentSection.BackgroundMapData2.Parameters["SelectedCapabilityIdentifier"] = selectedWmtsMapData.SelectedCapabilityIdentifier;
- assessmentSection.BackgroundMapData2.Parameters["PreferredFormat"] = selectedWmtsMapData.PreferredFormat;
+ assessmentSection.BackgroundData.Parameters["SourceCapabilitiesUrl"] = selectedWmtsMapData.SourceCapabilitiesUrl;
+ assessmentSection.BackgroundData.Parameters["SelectedCapabilityIdentifier"] = selectedWmtsMapData.SelectedCapabilityIdentifier;
+ assessmentSection.BackgroundData.Parameters["PreferredFormat"] = selectedWmtsMapData.PreferredFormat;
}
}
- assessmentSection.BackgroundMapData2.NotifyObservers();
+ assessmentSection.BackgroundData.NotifyObservers();
assessmentSection.NotifyObservers();
}
@@ -1118,7 +1117,7 @@
{
var childNodes = new List