Index: DamEngine/trunk/src/Deltares.DamEngine.Data/General/Segment.cs
===================================================================
diff -u -r877 -r941
--- DamEngine/trunk/src/Deltares.DamEngine.Data/General/Segment.cs (.../Segment.cs) (revision 877)
+++ DamEngine/trunk/src/Deltares.DamEngine.Data/General/Segment.cs (.../Segment.cs) (revision 941)
@@ -21,104 +21,13 @@
using System;
using System.Collections.Generic;
-using System.Globalization;
using System.Linq;
using System.Text;
using Deltares.DamEngine.Data.Geotechnics;
namespace Deltares.DamEngine.Data.General
{
///
- /// Class holding the soilprofile (either 1D or 2D) and its probability
- ///
- public class SoilGeometryProbability
- {
- ///
- /// Gets or sets the name of the SoilProfile1D.
- ///
- ///
- /// The name of the soilgeometry1d.
- ///
- public virtual string SoilProfile1DName { get; set; }
-
- ///
- /// Gets or sets the soil profile 1D.
- ///
- ///
- /// The soil profile.
- ///
- public virtual SoilProfile1D SoilProfile1D { get; set; }
-
- ///
- /// Gets or sets the name of the SoilProfile2D.
- ///
- ///
- /// The name of the soilgeometry1d.
- ///
- public virtual string SoilProfile2DName { get; set; }
-
- ///
- /// Gets or sets the soilprofile2d.
- ///
- ///
- /// The soilprofile2d.
- ///
- public virtual SoilProfile2D SoilProfile2D { get; set; }
-
- ///
- /// Gets or sets the name of the sti file (that holds the 2D profile).
- ///
- ///
- /// The name of the soilgeometry2d.
- ///
-
- public virtual string StiFileName { get; set; }
-
- ///
- /// Gets or sets the type of the segment failure mechanism.
- ///
- ///
- /// The type of the segment failure mechanism.
- ///
- public virtual FailureMechanismSystemType? SegmentFailureMechanismType { get; set; }
-
- ///
- /// Gets or sets the probability of occurance; number between 0.0 and 100.0.
- ///
- ///
- /// The probability.
- ///
- public virtual double Probability { get; set; }
-
- ///
- /// Gets the type of the soil geometry.
- ///
- ///
- /// The type of the soil geometry.
- ///
- /// No soilprofile assigned
- public SoilProfileType SoilProfileType { get; set; }
-
- ///
- /// Returns a that represents this instance.
- ///
- ///
- /// A that represents this instance.
- ///
- public override string ToString()
- {
- if (SoilProfile1D != null)
- {
- return SoilProfile1D.Name;
- }
- else
- {
- return StiFileName;
- }
- }
- }
-
- ///
/// Class holding all soilprofiles (1D/2D) and their probabilities as segment.
///
public class Segment
Index: DamEngine/trunk/src/Deltares.DamEngine.Interface/ConversionHelper.cs
===================================================================
diff -u -r877 -r941
--- DamEngine/trunk/src/Deltares.DamEngine.Interface/ConversionHelper.cs (.../ConversionHelper.cs) (revision 877)
+++ DamEngine/trunk/src/Deltares.DamEngine.Interface/ConversionHelper.cs (.../ConversionHelper.cs) (revision 941)
@@ -579,7 +579,7 @@
///
/// Type of the validation result message.
///
- public static LogMessageType ConvertToMessageType(MessageMessageType validationResultMessageType)
+ public static LogMessageType ConvertToLogMessageType(MessageMessageType validationResultMessageType)
{
var translationTable = new Dictionary()
{
Index: DamEngine/trunk/src/Deltares.DamEngine.Interface/FillDamFromXmlOutput.cs
===================================================================
diff -u -r877 -r941
--- DamEngine/trunk/src/Deltares.DamEngine.Interface/FillDamFromXmlOutput.cs (.../FillDamFromXmlOutput.cs) (revision 877)
+++ DamEngine/trunk/src/Deltares.DamEngine.Interface/FillDamFromXmlOutput.cs (.../FillDamFromXmlOutput.cs) (revision 941)
@@ -81,7 +81,7 @@
{
var validationResult = output.Results.CalculationMessages[i];
var logMessage = new LogMessage();
- logMessage.MessageType = ConversionHelper.ConvertToMessageType(validationResult.MessageType);
+ logMessage.MessageType = ConversionHelper.ConvertToLogMessageType(validationResult.MessageType);
logMessage.Subject = null;
logMessage.Message = validationResult.Message1;
damProjectData.CalculationMessages.Add(logMessage);
Index: DamEngine/trunk/src/Deltares.DamEngine.Interface.Tests/ConversionHelperTests.cs
===================================================================
diff -u -r877 -r941
--- DamEngine/trunk/src/Deltares.DamEngine.Interface.Tests/ConversionHelperTests.cs (.../ConversionHelperTests.cs) (revision 877)
+++ DamEngine/trunk/src/Deltares.DamEngine.Interface.Tests/ConversionHelperTests.cs (.../ConversionHelperTests.cs) (revision 941)
@@ -217,7 +217,7 @@
[TestCase(3, FailureMechanismSystemType.HorizontalBalance)]
public void CanConvertToFailureMechanismSystemType(int inputFailureMechanismSystemType, FailureMechanismSystemType failureMechanismSystemType)
{
- Assert.AreEqual(inputFailureMechanismSystemType, ConversionHelper.ConvertToInputFailureMechanismSystemType(failureMechanismSystemType));
+ Assert.AreEqual(failureMechanismSystemType, ConversionHelper.ConvertToFailureMechanismSystemType(inputFailureMechanismSystemType));
}
[Test]
@@ -288,7 +288,7 @@
[TestCase(MessageMessageType.Warning, LogMessageType.Warning)]
public void CanConvertToMessageType(MessageMessageType messageType, LogMessageType logMessageType)
{
- Assert.AreEqual(logMessageType, ConversionHelper.ConvertToMessageType(messageType));
+ Assert.AreEqual(logMessageType, ConversionHelper.ConvertToLogMessageType(messageType));
}
[Test]
Index: DamEngine/trunk/src/Deltares.DamEngine.Data/General/SoilGeometryProbability.cs
===================================================================
diff -u
--- DamEngine/trunk/src/Deltares.DamEngine.Data/General/SoilGeometryProbability.cs (revision 0)
+++ DamEngine/trunk/src/Deltares.DamEngine.Data/General/SoilGeometryProbability.cs (revision 941)
@@ -0,0 +1,116 @@
+// Copyright (C) Stichting Deltares 2018. All rights reserved.
+//
+// This file is part of the Dam Engine.
+//
+// The Dam Engine is free software: you can redistribute it and/or modify
+// it under the terms of the GNU Affero General Public License as published by
+// the Free Software Foundation, either version 3 of the License, or
+// (at your option) any later version.
+//
+// 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 Affero General Public License for more details.
+//
+// You should have received a copy of the GNU Affero General Public License
+// along with this program. If not, see .
+//
+// All names, logos, and references to "Deltares" are registered trademarks of
+// Stichting Deltares and remain full property of Stichting Deltares at all times.
+// All rights reserved.
+
+using Deltares.DamEngine.Data.Geotechnics;
+
+namespace Deltares.DamEngine.Data.General
+{
+ ///
+ /// Class holding the soilprofile (either 1D or 2D) and its probability
+ ///
+ public class SoilGeometryProbability
+ {
+ ///
+ /// Gets or sets the name of the SoilProfile1D.
+ ///
+ ///
+ /// The name of the soilgeometry1d.
+ ///
+ public virtual string SoilProfile1DName { get; set; }
+
+ ///
+ /// Gets or sets the soil profile 1D.
+ ///
+ ///
+ /// The soil profile.
+ ///
+ public virtual SoilProfile1D SoilProfile1D { get; set; }
+
+ ///
+ /// Gets or sets the name of the SoilProfile2D.
+ ///
+ ///
+ /// The name of the soilgeometry1d.
+ ///
+ public virtual string SoilProfile2DName { get; set; }
+
+ ///
+ /// Gets or sets the soilprofile2d.
+ ///
+ ///
+ /// The soilprofile2d.
+ ///
+ public virtual SoilProfile2D SoilProfile2D { get; set; }
+
+ ///
+ /// Gets or sets the name of the sti file (that holds the 2D profile).
+ ///
+ ///
+ /// The name of the soilgeometry2d.
+ ///
+
+ public virtual string StiFileName { get; set; }
+
+ ///
+ /// Gets or sets the type of the segment failure mechanism.
+ ///
+ ///
+ /// The type of the segment failure mechanism.
+ ///
+ public virtual FailureMechanismSystemType? SegmentFailureMechanismType { get; set; }
+
+ ///
+ /// Gets or sets the probability of occurance; number between 0.0 and 100.0.
+ ///
+ ///
+ /// The probability.
+ ///
+ public virtual double Probability { get; set; }
+
+ ///
+ /// Gets the type of the soil geometry.
+ ///
+ ///
+ /// The type of the soil geometry.
+ ///
+ /// No soilprofile assigned
+ public SoilProfileType SoilProfileType { get; set; }
+
+ ///
+ /// Returns a that represents this instance.
+ ///
+ ///
+ /// A that represents this instance.
+ ///
+ public override string ToString()
+ {
+ if (SoilProfile1D != null)
+ {
+ return SoilProfile1D.Name;
+ }
+ else
+ {
+ return StiFileName;
+ }
+ }
+ }
+
+}
Index: DamEngine/trunk/src/Deltares.DamEngine.Data/Deltares.DamEngine.Data.csproj
===================================================================
diff -u -r877 -r941
--- DamEngine/trunk/src/Deltares.DamEngine.Data/Deltares.DamEngine.Data.csproj (.../Deltares.DamEngine.Data.csproj) (revision 877)
+++ DamEngine/trunk/src/Deltares.DamEngine.Data/Deltares.DamEngine.Data.csproj (.../Deltares.DamEngine.Data.csproj) (revision 941)
@@ -78,6 +78,7 @@
+