mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-10-27 14:27:15 +00:00
Using Collection instead of List where possible
This commit is contained in:
1 parent
2bbcd187f4
commit
d9ae7adcae
2 files changed
+5
-7
No files matched your search
+2
-2
@@ -1,7 +1,7 @@
|
||||
package com.sap.sailing.gwt.home.client.place.event.partials.racelist;
|
||||
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Collection;
|
||||
|
||||
import com.google.gwt.core.client.GWT;
|
||||
import com.google.gwt.dom.client.DivElement;
|
||||
@@ -31,7 +31,7 @@ public class RaceListContainer<T extends RaceMetadataDTO> extends Composite {
|
||||
this.titleUi.setInnerText(title);
|
||||
}
|
||||
|
||||
public void setRaceListData(List<T> data) {
|
||||
public void setRaceListData(Collection<T> data) {
|
||||
this.raceListUi.setTableData(data);
|
||||
}
|
||||
|
||||
|
||||
+3
-5
@@ -1,7 +1,6 @@
|
||||
package com.sap.sailing.gwt.home.client.place.event.regatta.tabs;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Collection;
|
||||
|
||||
import com.google.gwt.core.client.GWT;
|
||||
import com.google.gwt.dom.client.Style.Display;
|
||||
@@ -106,8 +105,7 @@ public class RegattaRacesTabView extends Composite implements RegattaTabView<Reg
|
||||
@Override
|
||||
public void onSuccess(ResultWithTTL<RaceListViewDTO> result) {
|
||||
liveRacesList.setData(result.getDto().getLiveRaces(), 0, 0);
|
||||
// TODO change setListData to use Collection
|
||||
finishedRacesList.setListData(new ArrayList<RaceListRaceDTO>(result.getDto().getAllRaces()));
|
||||
finishedRacesList.setListData(result.getDto().getAllRaces());
|
||||
// for (RaceListSeriesDTO series : result.getDto().getRacesForCompetitionFormat()) {
|
||||
// compFormatContainerUi.add(new RegattaCompetitionSeries(currentPresenter, series));
|
||||
// }
|
||||
@@ -152,7 +150,7 @@ public class RegattaRacesTabView extends Composite implements RegattaTabView<Reg
|
||||
super(presenter);
|
||||
}
|
||||
|
||||
public void setListData(List<RaceListRaceDTO> data) {
|
||||
public void setListData(Collection<RaceListRaceDTO> data) {
|
||||
// boolean hasFleets = data.hasFleets();
|
||||
// this.fleetCornerColumn.setShowDetails(hasFleets);
|
||||
// this.fleetNameColumn.setShowDetails(hasFleets);
|
||||
|
||||
Reference in new issue
Block a user