mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-10-07 04:41:00 +00:00
added total distance traveled to EventStatisticsDTO
This commit is contained in:
1 parent
6ece53bb6d
commit
8691ec0e7b
2 files changed
+9
-2
No files matched your search
+8
-1
@@ -1,6 +1,7 @@
|
||||
package com.sap.sailing.gwt.ui.shared.dispatch.event;
|
||||
|
||||
import com.sap.sailing.domain.base.Competitor;
|
||||
import com.sap.sailing.domain.common.Distance;
|
||||
import com.sap.sailing.domain.common.Speed;
|
||||
import com.sap.sailing.gwt.ui.shared.dispatch.DTO;
|
||||
import com.sap.sse.common.TimePoint;
|
||||
@@ -15,13 +16,14 @@ public class EventStatisticsDTO implements DTO {
|
||||
private long numberOfGPSFixes;
|
||||
private long numberOfWindFixes;
|
||||
private Triple<Competitor, Speed, TimePoint> maxSpeed;
|
||||
private Distance totalDistanceTraveled;
|
||||
|
||||
@SuppressWarnings("unused")
|
||||
private EventStatisticsDTO() {
|
||||
}
|
||||
|
||||
public EventStatisticsDTO(Integer regattasFoughtCount, Integer competitorsCount, Integer racesRunCount,
|
||||
Integer trackedRacesCount, long numberOfGPSFixes, long numberOfWindFixes, Triple<Competitor, Speed, TimePoint> maxSpeed) {
|
||||
Integer trackedRacesCount, long numberOfGPSFixes, long numberOfWindFixes, Triple<Competitor, Speed, TimePoint> maxSpeed, Distance totalDistanceTraveled) {
|
||||
super();
|
||||
this.regattasFoughtCount = regattasFoughtCount;
|
||||
this.competitorsCount = competitorsCount;
|
||||
@@ -30,6 +32,7 @@ public class EventStatisticsDTO implements DTO {
|
||||
this.numberOfGPSFixes = numberOfGPSFixes;
|
||||
this.numberOfWindFixes = numberOfWindFixes;
|
||||
this.maxSpeed = maxSpeed;
|
||||
this.totalDistanceTraveled = totalDistanceTraveled;
|
||||
}
|
||||
|
||||
public Integer getRegattasFoughtCount() {
|
||||
@@ -76,4 +79,8 @@ public class EventStatisticsDTO implements DTO {
|
||||
return maxSpeed;
|
||||
}
|
||||
|
||||
public Distance getTotalDistanceTraveled() {
|
||||
return totalDistanceTraveled;
|
||||
}
|
||||
|
||||
}
|
||||
+1
-1
@@ -105,6 +105,6 @@ public class GetEventStatisticsAction implements Action<ResultWithTTL<EventStati
|
||||
}
|
||||
}
|
||||
return new ResultWithTTL<EventStatisticsDTO>(1000 * 60 * 5, new EventStatisticsDTO(regattas, competitors,
|
||||
races, trackedRaces, numberOfGPSFixes, numberOfWindFixes, maxSpeed));
|
||||
races, trackedRaces, numberOfGPSFixes, numberOfWindFixes, maxSpeed, totalDistanceTraveled));
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user