|
@@ -28,15 +28,15 @@ public class Event {
|
|
|
return description;
|
|
return description;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- public void addTeam(Team t) {
|
|
|
|
|
|
|
+ public synchronized void addTeam(Team t) {
|
|
|
teams.put(t.getId(), t);
|
|
teams.put(t.getId(), t);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- public Collection<Team> getTeams() {
|
|
|
|
|
|
|
+ public synchronized Collection<Team> getTeams() {
|
|
|
return Collections.unmodifiableCollection(teams.values());
|
|
return Collections.unmodifiableCollection(teams.values());
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- public Team getTeam(UUID id) {
|
|
|
|
|
|
|
+ public synchronized Team getTeam(UUID id) {
|
|
|
return teams.get(id);
|
|
return teams.get(id);
|
|
|
}
|
|
}
|
|
|
|
|
|