/[projects]/android/TrainInfoService/src/dk/thoerup/traininfoservice/banedk/DepartureFetcher.java
ViewVC logotype

Diff of /android/TrainInfoService/src/dk/thoerup/traininfoservice/banedk/DepartureFetcher.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1251 by torben, Thu Mar 31 17:13:19 2011 UTC revision 1252 by torben, Mon Apr 4 08:27:24 2011 UTC
# Line 75  public class DepartureFetcher { Line 75  public class DepartureFetcher {
75                  StationEntry station = stationDao.getById(stationID);                  StationEntry station = stationDao.getById(stationID);
76                                    
77                  departureBean.stationName = station.getName();                  departureBean.stationName = station.getName();
78                    
79                  if (station.getRegional() != null && (type == FetchTrainType.REGIONAL||type == FetchTrainType.BOTH) ) {                  if (station.getRegional() != null && (type == FetchTrainType.REGIONAL||type == FetchTrainType.BOTH) ) {
80                          DepartureBean tempBean = lookupDepartures(station.getRegional(), TrainType.REGIONAL, arrival);                          DepartureBean tempBean = lookupDepartures(station.getRegional(), TrainType.REGIONAL, arrival);
81                          departureBean.entries.addAll( tempBean.entries );                          departureBean.entries.addAll( tempBean.entries );
# Line 92  public class DepartureFetcher { Line 92  public class DepartureFetcher {
92                          logger.info("No departures found for station " + stationID);                          logger.info("No departures found for station " + stationID);
93                  }                  }
94                                    
95                  Collections.sort( departureBean.entries );                  if (type == FetchTrainType.BOTH) { //if we have both S-tog and regional order by departure/arrival time
96                            Collections.sort( departureBean.entries );
97                    }
98    
99                                    
100                  return departureBean;                  return departureBean;

Legend:
Removed from v.1251  
changed lines
  Added in v.1252

  ViewVC Help
Powered by ViewVC 1.1.20