if (hopsFromStop == null) {
hopsFromStop = new ArrayList<StopHop>();
allHopsFromStop.put(fromStop, hopsFromStop);
}
hopsFromStop.add(new StopHop(toStop, minTravelTime));
/**
* To Stop
*/
List<StopHop> hopsToStop = allHopsToStop.get(toStop);
if (hopsToStop == null) {
hopsToStop = new ArrayList<StopHop>();
allHopsToStop.put(fromStop, hopsToStop);
}
hopsToStop.add(new StopHop(fromStop, minTravelTime));
}
for( Map.Entry<StopEntry, List<StopHop>> entry : allHopsFromStop.entrySet()) {
List<StopHop> value = entry.getValue();
value = new StopHopList(value);