mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-10-08 21:30:57 +00:00
initial version of a json service getting the race states for all races of an event
This commit is contained in:
1 parent
9fe35de42a
commit
5476d74f05
4 files changed
+149
-3
No files matched your search
+5
-1
@@ -41,5 +41,9 @@ public interface RaceLog extends Track<RaceLogEvent> {
|
||||
* Remove a listener.
|
||||
*/
|
||||
void removeListener(RaceLogEventVisitor listener);
|
||||
|
||||
|
||||
/**
|
||||
* Checks if the race log is empty.
|
||||
*/
|
||||
boolean isEmpty();
|
||||
}
|
||||
+5
-1
@@ -93,6 +93,11 @@ public class RaceLogImpl extends TrackImpl<RaceLogEvent> implements RaceLog {
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isEmpty() {
|
||||
return getFirstRawFix() == null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addListener(RaceLogEventVisitor listener) {
|
||||
synchronized (listeners) {
|
||||
@@ -124,5 +129,4 @@ public class RaceLogImpl extends TrackImpl<RaceLogEvent> implements RaceLog {
|
||||
ois.defaultReadObject();
|
||||
listeners = new HashSet<RaceLogEventVisitor>();
|
||||
}
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user