use of org.onebusaway.gtfs.impl.calendar.UnknownAgencyTimezoneException in project OpenTripPlanner by opentripplanner.
the class CalendarServiceDataFactoryImpl method setTimeZonesForAgencies.
private void setTimeZonesForAgencies(CalendarServiceData data) {
for (Agency agency : _dao.getAllAgencies()) {
TimeZone timeZone = TimeZone.getTimeZone(agency.getTimezone());
if (timeZone.getID().equals("GMT") && !agency.getTimezone().toUpperCase().equals("GMT")) {
throw new UnknownAgencyTimezoneException(agency.getName(), agency.getTimezone());
}
data.putTimeZoneForAgencyId(agency.getId(), timeZone);
}
}
Aggregations