Index: Core/Plugins/src/Core.Plugins.Map/PropertyClasses/MapPointDataProperties.cs =================================================================== diff -u -r54d2453c0bea232c1c507ef9996143e6af8e3a61 -r0b549f2e1d172c59c5b86ae7de9fba5b74a602ea --- Core/Plugins/src/Core.Plugins.Map/PropertyClasses/MapPointDataProperties.cs (.../MapPointDataProperties.cs) (revision 54d2453c0bea232c1c507ef9996143e6af8e3a61) +++ Core/Plugins/src/Core.Plugins.Map/PropertyClasses/MapPointDataProperties.cs (.../MapPointDataProperties.cs) (revision 0b549f2e1d172c59c5b86ae7de9fba5b74a602ea) @@ -176,7 +176,7 @@ { MapTheme mapTheme = data.Theme; return mapTheme != null - ? mapTheme.CategoryThemes.Select(ct => new PointCategoryThemeProperties(ct, mapTheme.AttributeName, data)).ToArray() + ? GetCategoryThemes(mapTheme) : new PointCategoryThemeProperties[0]; } } @@ -199,5 +199,10 @@ return base.DynamicVisibleValidationMethod(propertyName); } + + private PointCategoryThemeProperties[] GetCategoryThemes(MapTheme mapTheme) + { + return mapTheme.CategoryThemes.Select(ct => new PointCategoryThemeProperties(ct, mapTheme.AttributeName, data)).ToArray(); + } } } \ No newline at end of file Index: Core/Plugins/src/Core.Plugins.Map/PropertyClasses/MapPolygonDataProperties.cs =================================================================== diff -u -r54d2453c0bea232c1c507ef9996143e6af8e3a61 -r0b549f2e1d172c59c5b86ae7de9fba5b74a602ea --- Core/Plugins/src/Core.Plugins.Map/PropertyClasses/MapPolygonDataProperties.cs (.../MapPolygonDataProperties.cs) (revision 54d2453c0bea232c1c507ef9996143e6af8e3a61) +++ Core/Plugins/src/Core.Plugins.Map/PropertyClasses/MapPolygonDataProperties.cs (.../MapPolygonDataProperties.cs) (revision 0b549f2e1d172c59c5b86ae7de9fba5b74a602ea) @@ -137,7 +137,7 @@ { MapTheme mapTheme = data.Theme; return mapTheme != null - ? mapTheme.CategoryThemes.Select(ct => new PolygonCategoryThemeProperties(ct, mapTheme.AttributeName, data)).ToArray() + ? GetCategoryThemes(mapTheme) : new PolygonCategoryThemeProperties[0]; } } @@ -170,5 +170,10 @@ return base.DynamicReadonlyValidator(propertyName); } + + private PolygonCategoryThemeProperties[] GetCategoryThemes(MapTheme mapTheme) + { + return mapTheme.CategoryThemes.Select(ct => new PolygonCategoryThemeProperties(ct, mapTheme.AttributeName, data)).ToArray(); + } } } \ No newline at end of file Index: Riskeer/Common/src/Riskeer.Common.Forms/PropertyClasses/DesignWaterLevelCalculationsGroupProperties.cs =================================================================== diff -u -r247659d91db1609d27f3d565203f62bd5b70abcc -r0b549f2e1d172c59c5b86ae7de9fba5b74a602ea --- Riskeer/Common/src/Riskeer.Common.Forms/PropertyClasses/DesignWaterLevelCalculationsGroupProperties.cs (.../DesignWaterLevelCalculationsGroupProperties.cs) (revision 247659d91db1609d27f3d565203f62bd5b70abcc) +++ Riskeer/Common/src/Riskeer.Common.Forms/PropertyClasses/DesignWaterLevelCalculationsGroupProperties.cs (.../DesignWaterLevelCalculationsGroupProperties.cs) (revision 0b549f2e1d172c59c5b86ae7de9fba5b74a602ea) @@ -51,9 +51,14 @@ { get { - return data.Select(location => new DesignWaterLevelHydraulicBoundaryLocationProperties( - location, GetHydraulicBoundaryLocationCalculationsForLocation(location))).ToArray(); + return GetLocations(); } } + + private DesignWaterLevelHydraulicBoundaryLocationProperties[] GetLocations() + { + return data.Select(location => new DesignWaterLevelHydraulicBoundaryLocationProperties( + location, GetHydraulicBoundaryLocationCalculationsForLocation(location))).ToArray(); + } } } \ No newline at end of file Index: Riskeer/Common/src/Riskeer.Common.Forms/PropertyClasses/DesignWaterLevelCalculationsProperties.cs =================================================================== diff -u -r247659d91db1609d27f3d565203f62bd5b70abcc -r0b549f2e1d172c59c5b86ae7de9fba5b74a602ea --- Riskeer/Common/src/Riskeer.Common.Forms/PropertyClasses/DesignWaterLevelCalculationsProperties.cs (.../DesignWaterLevelCalculationsProperties.cs) (revision 247659d91db1609d27f3d565203f62bd5b70abcc) +++ Riskeer/Common/src/Riskeer.Common.Forms/PropertyClasses/DesignWaterLevelCalculationsProperties.cs (.../DesignWaterLevelCalculationsProperties.cs) (revision 0b549f2e1d172c59c5b86ae7de9fba5b74a602ea) @@ -50,8 +50,13 @@ { get { - return data.Select(calculation => new DesignWaterLevelCalculationProperties(calculation)).ToArray(); + return GetCalculations(); } } + + private DesignWaterLevelCalculationProperties[] GetCalculations() + { + return data.Select(calculation => new DesignWaterLevelCalculationProperties(calculation)).ToArray(); + } } } \ No newline at end of file Index: Riskeer/Common/src/Riskeer.Common.Forms/PropertyClasses/DesignWaterLevelHydraulicBoundaryLocationProperties.cs =================================================================== diff -u -r247659d91db1609d27f3d565203f62bd5b70abcc -r0b549f2e1d172c59c5b86ae7de9fba5b74a602ea --- Riskeer/Common/src/Riskeer.Common.Forms/PropertyClasses/DesignWaterLevelHydraulicBoundaryLocationProperties.cs (.../DesignWaterLevelHydraulicBoundaryLocationProperties.cs) (revision 247659d91db1609d27f3d565203f62bd5b70abcc) +++ Riskeer/Common/src/Riskeer.Common.Forms/PropertyClasses/DesignWaterLevelHydraulicBoundaryLocationProperties.cs (.../DesignWaterLevelHydraulicBoundaryLocationProperties.cs) (revision 0b549f2e1d172c59c5b86ae7de9fba5b74a602ea) @@ -53,9 +53,14 @@ { get { - return CalculationPerCategoryBoundary.Select(calculation => new DesignWaterLevelCalculationCategoryBoundaryProperties(calculation.Item2, - calculation.Item1)).ToArray(); + return GetCategoryBoundaries(); } } + + private DesignWaterLevelCalculationCategoryBoundaryProperties[] GetCategoryBoundaries() + { + return CalculationPerCategoryBoundary.Select(calculation => new DesignWaterLevelCalculationCategoryBoundaryProperties(calculation.Item2, + calculation.Item1)).ToArray(); + } } } \ No newline at end of file