assume only Number, not Integer or Double; types don't survive backup/restore as of now

Change-Id: I1e07dfca2859e76e99e2380d4dbe0eee6379aa73
This commit is contained in:
Axel Uhl
2018-10-12 16:29:34 +02:00
parent 3a07f8dea4
commit 1f56437873
@@ -558,7 +558,7 @@ public class DomainObjectFactoryImpl implements DomainObjectFactory {
.size()];
int i = 0;
for (Object discardingThresholdAsObject : dbDiscardIndexResultsStartingWithHowManyRaces) {
discardIndexResultsStartingWithHowManyRaces[i++] = (Integer) discardingThresholdAsObject;
discardIndexResultsStartingWithHowManyRaces[i++] = ((Number) discardingThresholdAsObject).intValue();
}
result = new ThresholdBasedResultDiscardingRuleImpl(discardIndexResultsStartingWithHowManyRaces);
}
@@ -1266,8 +1266,9 @@ public class DomainObjectFactoryImpl implements DomainObjectFactory {
logger.log(Level.WARNING, "Error loading racing procedure configration for regatta.", e);
}
}
final Double buoyZoneRadiusInHullLengths = (Double) dbRegatta
final Number buoyZoneRadiusInHullLengthsAsNumber = (Number) dbRegatta
.get(FieldNames.REGATTA_BUOY_ZONE_RADIUS_IN_HULL_LENGTHS.name());
final Double buoyZoneRadiusInHullLengths = buoyZoneRadiusInHullLengthsAsNumber==null?null:(Double) buoyZoneRadiusInHullLengthsAsNumber.doubleValue();
final Boolean useStartTimeInference = (Boolean) dbRegatta
.get(FieldNames.REGATTA_USE_START_TIME_INFERENCE.name());
final Boolean controlTrackingFromStartAndFinishTimes = (Boolean) dbRegatta