mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-10-07 21:01:03 +00:00
Moved AggregatorType and StatisticType to Components
This commit is contained in:
1 parent
985c3ad2c4
commit
a928c37295
15 files changed
+57
-53
No files matched your search
+5
-5
@@ -20,13 +20,13 @@ import com.sap.sailing.datamining.impl.criterias.AndCompoundFilterCriteria;
|
||||
import com.sap.sailing.datamining.impl.criterias.CompoundFilterCriteria;
|
||||
import com.sap.sailing.datamining.impl.criterias.DimensionValuesFilterCriteria;
|
||||
import com.sap.sailing.datamining.impl.gpsfix.GPSFixBaseBindingProvider;
|
||||
import com.sap.sailing.datamining.impl.gpsfix.SimpleGPSFixRetriever;
|
||||
import com.sap.sailing.datamining.impl.gpsfix.GPSFixRetriever;
|
||||
import com.sap.sailing.datamining.impl.gpsfix.GroupGPSFixesByDimension;
|
||||
import com.sap.sailing.datamining.shared.AggregatorType;
|
||||
import com.sap.sailing.datamining.shared.Components.AggregatorType;
|
||||
import com.sap.sailing.datamining.shared.Components.StatisticType;
|
||||
import com.sap.sailing.datamining.shared.DataTypes;
|
||||
import com.sap.sailing.datamining.shared.SharedDimension;
|
||||
import com.sap.sailing.datamining.shared.QueryDefinition;
|
||||
import com.sap.sailing.datamining.shared.StatisticType;
|
||||
import com.sap.sailing.datamining.shared.SharedDimension;
|
||||
import com.sap.sailing.domain.base.Moving;
|
||||
|
||||
public class DataMiningFactory {
|
||||
@@ -64,7 +64,7 @@ public class DataMiningFactory {
|
||||
}
|
||||
|
||||
public static DataRetriever<GPSFixWithContext> createGPSFixRetriever() {
|
||||
return new SimpleGPSFixRetriever();
|
||||
return new GPSFixRetriever();
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
+2
-2
@@ -3,12 +3,12 @@ package com.sap.sailing.datamining.impl;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import com.sap.sailing.datamining.shared.AggregatorType;
|
||||
import com.sap.sailing.datamining.shared.Components.AggregatorType;
|
||||
import com.sap.sailing.datamining.shared.Components.GrouperType;
|
||||
import com.sap.sailing.datamining.shared.Components.StatisticType;
|
||||
import com.sap.sailing.datamining.shared.DataTypes;
|
||||
import com.sap.sailing.datamining.shared.QueryDefinition;
|
||||
import com.sap.sailing.datamining.shared.SharedDimension;
|
||||
import com.sap.sailing.datamining.shared.StatisticType;
|
||||
|
||||
public class SmartQueryDefinition implements QueryDefinition {
|
||||
private static final long serialVersionUID = -4195720362233906108L;
|
||||
|
||||
+1
-1
@@ -21,7 +21,7 @@ import com.sap.sailing.domain.tracking.TrackedLegOfCompetitor;
|
||||
import com.sap.sailing.domain.tracking.TrackedRace;
|
||||
import com.sap.sailing.server.RacingEventService;
|
||||
|
||||
public class SimpleGPSFixRetriever implements DataRetriever<GPSFixWithContext> {
|
||||
public class GPSFixRetriever implements DataRetriever<GPSFixWithContext> {
|
||||
|
||||
@Override
|
||||
public Collection<GPSFixWithContext> retrieveData(RacingEventService racingEventService) {
|
||||
-7
@@ -1,7 +0,0 @@
|
||||
package com.sap.sailing.datamining.shared;
|
||||
|
||||
public enum AggregatorType {
|
||||
|
||||
Sum, Average
|
||||
|
||||
}
|
||||
+31
-4
@@ -1,9 +1,36 @@
|
||||
package com.sap.sailing.datamining.shared;
|
||||
|
||||
public final class Components {
|
||||
|
||||
public enum GrouperType { Dimensions, Custom }
|
||||
|
||||
private Components() { }
|
||||
|
||||
public enum GrouperType {
|
||||
Dimensions, Custom
|
||||
}
|
||||
|
||||
public enum AggregatorType {
|
||||
Sum, Average
|
||||
}
|
||||
|
||||
public enum StatisticType {
|
||||
|
||||
DataAmount(ValueType.Integer), Speed(ValueType.Double);
|
||||
|
||||
public static enum ValueType {
|
||||
Integer, Double
|
||||
}
|
||||
|
||||
private ValueType valueType;
|
||||
|
||||
private StatisticType(ValueType valueType) {
|
||||
this.valueType = valueType;
|
||||
}
|
||||
|
||||
public ValueType getValueType() {
|
||||
return valueType;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
private Components() {
|
||||
}
|
||||
|
||||
}
|
||||
+2
@@ -4,7 +4,9 @@ import java.io.Serializable;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import com.sap.sailing.datamining.shared.Components.AggregatorType;
|
||||
import com.sap.sailing.datamining.shared.Components.GrouperType;
|
||||
import com.sap.sailing.datamining.shared.Components.StatisticType;
|
||||
|
||||
public interface QueryDefinition extends Serializable {
|
||||
|
||||
|
||||
+2
@@ -6,7 +6,9 @@ import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import com.sap.sailing.datamining.shared.Components.AggregatorType;
|
||||
import com.sap.sailing.datamining.shared.Components.GrouperType;
|
||||
import com.sap.sailing.datamining.shared.Components.StatisticType;
|
||||
|
||||
public class SimpleQueryDefinition implements QueryDefinition {
|
||||
private static final long serialVersionUID = 3476324726640558091L;
|
||||
|
||||
-20
@@ -1,20 +0,0 @@
|
||||
package com.sap.sailing.datamining.shared;
|
||||
|
||||
public enum StatisticType {
|
||||
|
||||
DataAmount(ValueType.Integer),
|
||||
Speed(ValueType.Double);
|
||||
|
||||
public static enum ValueType {Integer, Double}
|
||||
|
||||
private ValueType valueType;
|
||||
|
||||
private StatisticType(ValueType valueType) {
|
||||
this.valueType = valueType;
|
||||
}
|
||||
|
||||
public ValueType getValueType() {
|
||||
return valueType;
|
||||
}
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user