Index: DamClients/DamUI/trunk/src/DamClientsLibrary/Deltares.Dam.Data/DamEngineIo/FillXmlInputFromDamUi.cs =================================================================== diff -u -r2570 -r2572 --- DamClients/DamUI/trunk/src/DamClientsLibrary/Deltares.Dam.Data/DamEngineIo/FillXmlInputFromDamUi.cs (.../FillXmlInputFromDamUi.cs) (revision 2570) +++ DamClients/DamUI/trunk/src/DamClientsLibrary/Deltares.Dam.Data/DamEngineIo/FillXmlInputFromDamUi.cs (.../FillXmlInputFromDamUi.cs) (revision 2572) @@ -591,10 +591,10 @@ inputDesignScenario.RiverLevelLow = designScenario.RiverLevelLow ?? 0.0; inputDesignScenario.DikeTableHeightSpecified = designScenario.DikeTableHeight.HasValue; inputDesignScenario.DikeTableHeight = designScenario.DikeTableHeight ?? 0.0; - inputDesignScenario.PlLineOffsetBelowDikeTopAtRiver = designScenario.PlLineOffsetBelowDikeTopAtRiver.Value; - inputDesignScenario.PlLineOffsetBelowDikeTopAtPolder = designScenario.PlLineOffsetBelowDikeTopAtPolder.Value; - inputDesignScenario.PlLineOffsetBelowShoulderBaseInside = designScenario.PlLineOffsetBelowShoulderBaseInside.Value; - inputDesignScenario.PlLineOffsetBelowDikeToeAtPolder = designScenario.PlLineOffsetBelowDikeToeAtPolder.Value; + inputDesignScenario.PlLineOffsetBelowDikeTopAtRiver = designScenario.PlLineOffsetBelowDikeTopAtRiver; + inputDesignScenario.PlLineOffsetBelowDikeTopAtPolder = designScenario.PlLineOffsetBelowDikeTopAtPolder; + inputDesignScenario.PlLineOffsetBelowShoulderBaseInside = designScenario.PlLineOffsetBelowShoulderBaseInside; + inputDesignScenario.PlLineOffsetBelowDikeToeAtPolder = designScenario.PlLineOffsetBelowDikeToeAtPolder; inputDesignScenario.PlLineOffsetBelowDikeCrestMiddleSpecified = designScenario.UsePlLineOffsetBelowDikeCrestMiddle ?? false; inputDesignScenario.PlLineOffsetBelowDikeCrestMiddle = designScenario.PlLineOffsetBelowDikeCrestMiddle ?? 0.0; inputDesignScenario.PlLineOffsetFactorBelowShoulderCrestSpecified = designScenario.UsePlLineOffsetFactorBelowShoulderCrest ?? false; Index: DamClients/DamUI/trunk/src/DamClientsLibrary/Deltares.Dam.Data/Scenario.cs =================================================================== diff -u -r2571 -r2572 --- DamClients/DamUI/trunk/src/DamClientsLibrary/Deltares.Dam.Data/Scenario.cs (.../Scenario.cs) (revision 2571) +++ DamClients/DamUI/trunk/src/DamClientsLibrary/Deltares.Dam.Data/Scenario.cs (.../Scenario.cs) (revision 2572) @@ -103,10 +103,10 @@ private double? riverLevel; private double? riverLevelLow; private double? dikeTableHeight; - private double? plLineOffsetBelowDikeTopAtRiver = 0.5; - private double? plLineOffsetBelowDikeTopAtPolder = 1.5; - private double? plLineOffsetBelowShoulderBaseInside = 0.1; - private double? plLineOffsetBelowDikeToeAtPolder = 0.1; + private double plLineOffsetBelowDikeTopAtRiver = 0.5; + private double plLineOffsetBelowDikeTopAtPolder = 1.5; + private double plLineOffsetBelowShoulderBaseInside = 0.1; + private double plLineOffsetBelowDikeToeAtPolder = 0.1; private bool? usePlLineOffsetBelowDikeCrestMiddle; private double? plLineOffsetBelowDikeCrestMiddle; private bool? usePlLineOffsetFactorBelowShoulderCrest; @@ -375,7 +375,7 @@ [PropertyOrder(1, 10)] [Unit(UnitType.Length)] [Format("F2")] - public double? PlLineOffsetBelowDikeTopAtRiver + public double PlLineOffsetBelowDikeTopAtRiver { get { @@ -398,7 +398,7 @@ [PropertyOrder(1, 10)] [Unit(UnitType.Length)] [Format("F2")] - public double? PlLineOffsetBelowDikeTopAtPolder + public double PlLineOffsetBelowDikeTopAtPolder { get { @@ -421,7 +421,7 @@ [PropertyOrder(1, 11)] [Unit(UnitType.Length)] [Format("F2")] - public double? PlLineOffsetBelowShoulderBaseInside + public double PlLineOffsetBelowShoulderBaseInside { get { @@ -444,7 +444,7 @@ [PropertyOrder(1, 12)] [Unit(UnitType.Length)] [Format("F2")] - public double? PlLineOffsetBelowDikeToeAtPolder + public double PlLineOffsetBelowDikeToeAtPolder { get { @@ -942,20 +942,26 @@ { return String.Format("Location={0}, ID={1} RiverLevel={2} RiverLevelLow={3} DikeTableHeight={4} RequiredSafetyFactorStabilityInnerSlope={5} RequiredSafetyFactorStabilityOuterSlope={6} PlLineOffsetBelowDikeTopAtRiver={7} PlLineOffsetBelowDikeToeAtPolder={8} PlLineOffsetBelowDikeTopAtPolder={9} PlLineOffsetBelowShoulderBaseInside={10} UsePlLineOffsetBelowDikeCrestMiddle {11} PlLineOffsetBelowDikeCrestMiddle {12} UsePlLineOffsetFactorBelowShoulderCrest {13} PlLineOffsetFactorBelowShoulderCrest {14} HeadPl3={15} HeadPl4={16}", Location.Name, LocationScenarioID, RiverLevel, - RiverLevelLow.HasValue ? RiverLevelLow.ToString() : "?", - DikeTableHeight.HasValue ? DikeTableHeight.ToString() : "?", - ModelFactors.RequiredSafetyFactorStabilityInnerSlope.HasValue ? ModelFactors.RequiredSafetyFactorStabilityInnerSlope.ToString() : "?", - ModelFactors.RequiredSafetyFactorStabilityOuterSlope.HasValue ? ModelFactors.RequiredSafetyFactorStabilityOuterSlope.ToString() : "?", - PlLineOffsetBelowDikeTopAtRiver.HasValue ? PlLineOffsetBelowDikeToeAtPolder.ToString() : "?", - PlLineOffsetBelowDikeToeAtPolder.HasValue ? PlLineOffsetBelowDikeToeAtPolder.ToString() : "?", - PlLineOffsetBelowDikeTopAtPolder.HasValue ? PlLineOffsetBelowDikeTopAtPolder.ToString() : "?", - PlLineOffsetBelowShoulderBaseInside.HasValue ? PlLineOffsetBelowShoulderBaseInside.ToString() : "?", - UsePlLineOffsetBelowDikeCrestMiddle.HasValue ? UsePlLineOffsetBelowDikeCrestMiddle.ToString() : "?", - PlLineOffsetBelowDikeCrestMiddle.HasValue ? PlLineOffsetBelowDikeCrestMiddle.ToString() : "?", - UsePlLineOffsetFactorBelowShoulderCrest.HasValue ? UsePlLineOffsetFactorBelowShoulderCrest.ToString() : "?", - PlLineOffsetFactorBelowShoulderCrest.HasValue ? PlLineOffsetFactorBelowShoulderCrest.ToString() : "?", - HeadPl3.HasValue ? HeadPl3.ToString() : "?", - HeadPl4.HasValue ? HeadPl4.ToString() : "?"); + RiverLevelLow.HasValue ? RiverLevelLow.Value.ToString(CultureInfo.InvariantCulture) : "?", + DikeTableHeight.HasValue ? DikeTableHeight.Value.ToString(CultureInfo.InvariantCulture) : "?", + ModelFactors.RequiredSafetyFactorStabilityInnerSlope.HasValue ? + ModelFactors.RequiredSafetyFactorStabilityInnerSlope.Value.ToString(CultureInfo.InvariantCulture) : "?", + ModelFactors.RequiredSafetyFactorStabilityOuterSlope.HasValue ? + ModelFactors.RequiredSafetyFactorStabilityOuterSlope.Value.ToString(CultureInfo.InvariantCulture) : "?", + PlLineOffsetBelowDikeTopAtRiver.ToString(CultureInfo.InvariantCulture), + PlLineOffsetBelowDikeToeAtPolder.ToString(CultureInfo.InvariantCulture), + PlLineOffsetBelowDikeTopAtPolder.ToString(CultureInfo.InvariantCulture), + PlLineOffsetBelowShoulderBaseInside.ToString(CultureInfo.InvariantCulture), + UsePlLineOffsetBelowDikeCrestMiddle.HasValue ? + UsePlLineOffsetBelowDikeCrestMiddle.Value.ToString(CultureInfo.InvariantCulture) : "?", + PlLineOffsetBelowDikeCrestMiddle.HasValue ? + PlLineOffsetBelowDikeCrestMiddle.Value.ToString(CultureInfo.InvariantCulture) : "?", + UsePlLineOffsetFactorBelowShoulderCrest.HasValue ? + UsePlLineOffsetFactorBelowShoulderCrest.Value.ToString(CultureInfo.InvariantCulture) : "?", + PlLineOffsetFactorBelowShoulderCrest.HasValue ? + PlLineOffsetFactorBelowShoulderCrest.Value.ToString(CultureInfo.InvariantCulture) : "?", + HeadPl3.HasValue ? HeadPl3.Value.ToString(CultureInfo.InvariantCulture) : "?", + HeadPl4.HasValue ? HeadPl4.Value.ToString(CultureInfo.InvariantCulture) : "?"); } public Dictionary GetParametersAsNameValuePairs() @@ -999,22 +1005,10 @@ nameValuePairs.Add(ScenarioParameterNames.UpliftCriterionStability, ModelFactors.UpliftCriterionStability.Value.ToString(numberFormatInfo)); } } - if (PlLineOffsetBelowDikeTopAtRiver != null) - { - nameValuePairs.Add(ScenarioParameterNames.PlLineOffsetBelowDikeTopAtRiver, PlLineOffsetBelowDikeTopAtRiver.Value.ToString(numberFormatInfo)); - } - if (PlLineOffsetBelowDikeTopAtPolder != null) - { - nameValuePairs.Add(ScenarioParameterNames.PlLineOffsetBelowDikeTopAtPolder, PlLineOffsetBelowDikeTopAtPolder.Value.ToString(numberFormatInfo)); - } - if (PlLineOffsetBelowShoulderBaseInside != null) - { - nameValuePairs.Add(ScenarioParameterNames.PlLineOffsetBelowShoulderBaseInside, PlLineOffsetBelowShoulderBaseInside.Value.ToString(numberFormatInfo)); - } - if (PlLineOffsetBelowDikeToeAtPolder != null) - { - nameValuePairs.Add(ScenarioParameterNames.PlLineOffsetBelowDikeToeAtPolder, PlLineOffsetBelowDikeToeAtPolder.Value.ToString(numberFormatInfo)); - } + nameValuePairs.Add(ScenarioParameterNames.PlLineOffsetBelowDikeTopAtRiver, PlLineOffsetBelowDikeTopAtRiver.ToString(numberFormatInfo)); + nameValuePairs.Add(ScenarioParameterNames.PlLineOffsetBelowDikeTopAtPolder, PlLineOffsetBelowDikeTopAtPolder.ToString(numberFormatInfo)); + nameValuePairs.Add(ScenarioParameterNames.PlLineOffsetBelowShoulderBaseInside, PlLineOffsetBelowShoulderBaseInside.ToString(numberFormatInfo)); + nameValuePairs.Add(ScenarioParameterNames.PlLineOffsetBelowDikeToeAtPolder, PlLineOffsetBelowDikeToeAtPolder.ToString(numberFormatInfo)); if (PlLineOffsetBelowDikeCrestMiddle != null) { nameValuePairs.Add(ScenarioParameterNames.PlLineOffsetBelowDikeCrestMiddle, PlLineOffsetBelowDikeCrestMiddle.Value.ToString(numberFormatInfo));