Changeset View
Changeset View
Standalone View
Standalone View
src/it/reyboz/bustorino/backend/Stop.java
Show First 20 Lines • Show All 109 Lines • ▼ Show 20 Lines | public class Stop implements Comparable<Stop> { | ||||
public void setAbsurdGTTPlaceName(@NonNull String absurdGTTPlaceName) { | public void setAbsurdGTTPlaceName(@NonNull String absurdGTTPlaceName) { | ||||
this.absurdGTTPlaceName = absurdGTTPlaceName; | this.absurdGTTPlaceName = absurdGTTPlaceName; | ||||
} | } | ||||
public void setRoutesThatStopHere(@Nullable List<String> routesThatStopHere) { | public void setRoutesThatStopHere(@Nullable List<String> routesThatStopHere) { | ||||
this.routesThatStopHere = routesThatStopHere; | this.routesThatStopHere = routesThatStopHere; | ||||
} | } | ||||
protected void setRoutesThatStopHereString(String routesStopping){ | |||||
this.routesThatStopHereString = routesStopping; | |||||
} | |||||
@Nullable | @Nullable | ||||
protected List<String> getRoutesThatStopHere(){ | protected List<String> getRoutesThatStopHere(){ | ||||
return routesThatStopHere; | return routesThatStopHere; | ||||
} | } | ||||
private @Nullable String buildRoutesString() { | protected @Nullable String buildRoutesString() { | ||||
// no routes => no string | // no routes => no string | ||||
if(this.routesThatStopHere == null || this.routesThatStopHere.size() == 0) { | if(this.routesThatStopHere == null || this.routesThatStopHere.size() == 0) { | ||||
return null; | return null; | ||||
} | } | ||||
StringBuilder sb = new StringBuilder(); | StringBuilder sb = new StringBuilder(); | ||||
Collections.sort(routesThatStopHere,new LinesNameSorter()); | Collections.sort(routesThatStopHere,new LinesNameSorter()); | ||||
int i, lenMinusOne = routesThatStopHere.size() - 1; | int i, lenMinusOne = routesThatStopHere.size() - 1; | ||||
▲ Show 20 Lines • Show All 167 Lines • Show Last 20 Lines |
Public contents are in Creative Commons Attribution-ShareAlike 4.0 (CC-BY-SA) or GNU Free Documentation License (at your option) unless otherwise noted. · Contact / Register