Search in sources :

Example 1 with Alert

use of com.google.transit.realtime.GtfsRealtime.Alert in project onebusaway-application-modules by camsys.

the class AlertConvertor method readFeedEntity.

@Override
public AlertModel readFeedEntity(FeedEntity entity, long timestamp) {
    if (entity.hasAlert()) {
        AlertModel alrt = new AlertModel();
        alrt.setTimestamp(new Date(timestamp));
        Alert alert = entity.getAlert();
        for (TimeRange tr : alert.getActivePeriodList()) {
            TimeRangeModel timeRange = readTimeRange(tr);
            if (timeRange != null) {
                timeRange.setAlert(alrt);
                alrt.addTimeRangeModel(timeRange);
            }
        }
        for (EntitySelector es : alert.getInformedEntityList()) {
            EntitySelectorModel entitySelector = readEntitySelector(es);
            if (entitySelector != null) {
                entitySelector.setAlert(alrt);
                alrt.addEntitySelectorModel(entitySelector);
            }
        }
        if (alert.hasCause()) {
            String cause = alert.getCause().getValueDescriptor().getFullName();
            cause = cause.substring(cause.lastIndexOf('.') + 1);
            alrt.setCause(cause);
        }
        if (alert.hasEffect()) {
            String effect = alert.getEffect().getValueDescriptor().getFullName();
            effect = effect.substring(effect.lastIndexOf('.') + 1);
            alrt.setEffect(effect);
        }
        if (alert.hasUrl()) {
            alrt.setUrl(alert.getUrl().getTranslation(0).getText());
        }
        if (alert.hasHeaderText()) {
            alrt.setHeaderText(alert.getHeaderText().getTranslation(0).getText());
        }
        if (alert.hasDescriptionText()) {
            alrt.setDescriptionText(alert.getDescriptionText().getTranslation(0).getText());
        }
        return alrt;
    }
    return null;
}
Also used : TimeRange(com.google.transit.realtime.GtfsRealtime.TimeRange) EntitySelector(com.google.transit.realtime.GtfsRealtime.EntitySelector) AlertModel(org.onebusaway.gtfs_realtime.model.AlertModel) Alert(com.google.transit.realtime.GtfsRealtime.Alert) TimeRangeModel(org.onebusaway.gtfs_realtime.model.TimeRangeModel) EntitySelectorModel(org.onebusaway.gtfs_realtime.model.EntitySelectorModel) Date(java.util.Date)

Example 2 with Alert

use of com.google.transit.realtime.GtfsRealtime.Alert in project onebusaway-application-modules by camsys.

the class AlertsForAgencyActionTest method test.

@Test
public void test() {
    long now = System.currentTimeMillis();
    List<ServiceAlertBean> alerts = new ArrayList<ServiceAlertBean>();
    {
        ServiceAlertBean alert = new ServiceAlertBean();
        alerts.add(alert);
        TimeRangeBean range = new TimeRangeBean(1234 * 1000, 5678 * 1000);
        alert.setActiveWindows(Arrays.asList(range));
        SituationAffectsBean affects = new SituationAffectsBean();
        affects.setAgencyId("1");
        affects.setRouteId("1_r0");
        affects.setStopId("1_s0");
        affects.setTripId("1_t0");
        SituationAffectsBean alsoAffects = new SituationAffectsBean();
        alsoAffects.setAgencyId("2");
        alert.setAllAffects(Arrays.asList(affects, alsoAffects));
        alert.setSummaries(Arrays.asList(new NaturalLanguageStringBean("Name", "en"), new NaturalLanguageStringBean("Nombre", "es")));
        alert.setDescriptions(Arrays.asList(new NaturalLanguageStringBean("Description", "en"), new NaturalLanguageStringBean("DescripciĆ³n", "es")));
    }
    {
        ServiceAlertBean alert = new ServiceAlertBean();
        alerts.add(alert);
        TimeRangeBean range = new TimeRangeBean(5678 * 1000, 1234 * 1000);
        alert.setActiveWindows(Arrays.asList(range));
        SituationAffectsBean affects = new SituationAffectsBean();
        affects.setAgencyId("2");
        affects.setRouteId("1_r1");
        affects.setStopId("1_s1");
        affects.setTripId("1_t1");
        alert.setAllAffects(Arrays.asList(affects));
        alert.setSummaries(Arrays.asList(new NaturalLanguageStringBean("Name", "en")));
        alert.setDescriptions(Arrays.asList(new NaturalLanguageStringBean("Description", "en")));
    }
    ListBean<ServiceAlertBean> bean = new ListBean<ServiceAlertBean>();
    bean.setList(alerts);
    Mockito.when(_service.getAllServiceAlertsForAgencyId("1")).thenReturn(bean);
    _action.setId("1");
    _action.setTime(new Date(now));
    _action.show();
    ResponseBean model = _action.getModel();
    FeedMessage feed = (FeedMessage) model.getData();
    assertEquals(now / 1000, feed.getHeader().getTimestamp());
    assertEquals(2, feed.getEntityCount());
    {
        FeedEntity entity = feed.getEntity(0);
        assertEquals("1", entity.getId());
        Alert alert = entity.getAlert();
        assertEquals(1, alert.getActivePeriodCount());
        TimeRange range = alert.getActivePeriod(0);
        assertEquals(1234, range.getStart());
        assertEquals(5678, range.getEnd());
        assertEquals(2, alert.getInformedEntityCount());
        {
            EntitySelector affects = alert.getInformedEntity(0);
            assertEquals("1", affects.getAgencyId());
            assertEquals("r0", affects.getRouteId());
            assertEquals("t0", affects.getTrip().getTripId());
            assertEquals("s0", affects.getStopId());
        }
        {
            EntitySelector affects = alert.getInformedEntity(1);
            assertEquals("2", affects.getAgencyId());
        }
        TranslatedString header = alert.getHeaderText();
        assertEquals(2, header.getTranslationCount());
        {
            Translation translation = header.getTranslation(0);
            assertEquals("Name", translation.getText());
            assertEquals("en", translation.getLanguage());
        }
        {
            Translation translation = header.getTranslation(1);
            assertEquals("Nombre", translation.getText());
            assertEquals("es", translation.getLanguage());
        }
        TranslatedString description = alert.getDescriptionText();
        assertEquals(2, description.getTranslationCount());
        {
            Translation translation = description.getTranslation(0);
            assertEquals("Description", translation.getText());
            assertEquals("en", translation.getLanguage());
        }
        {
            Translation translation = description.getTranslation(1);
            assertEquals("DescripciĆ³n", translation.getText());
            assertEquals("es", translation.getLanguage());
        }
    }
    {
        FeedEntity entity = feed.getEntity(1);
        assertEquals("2", entity.getId());
        Alert alert = entity.getAlert();
        assertEquals(1, alert.getActivePeriodCount());
        TimeRange range = alert.getActivePeriod(0);
        assertEquals(5678, range.getStart());
        assertEquals(1234, range.getEnd());
        assertEquals(1, alert.getInformedEntityCount());
        {
            EntitySelector affects = alert.getInformedEntity(0);
            assertEquals("2", affects.getAgencyId());
            assertEquals("r1", affects.getRouteId());
            assertEquals("t1", affects.getTrip().getTripId());
            assertEquals("s1", affects.getStopId());
        }
    }
}
Also used : TranslatedString(com.google.transit.realtime.GtfsRealtime.TranslatedString) EntitySelector(com.google.transit.realtime.GtfsRealtime.EntitySelector) Translation(com.google.transit.realtime.GtfsRealtime.TranslatedString.Translation) ArrayList(java.util.ArrayList) ListBean(org.onebusaway.transit_data.model.ListBean) Date(java.util.Date) TimeRangeBean(org.onebusaway.transit_data.model.service_alerts.TimeRangeBean) TimeRange(com.google.transit.realtime.GtfsRealtime.TimeRange) FeedMessage(com.google.transit.realtime.GtfsRealtime.FeedMessage) SituationAffectsBean(org.onebusaway.transit_data.model.service_alerts.SituationAffectsBean) NaturalLanguageStringBean(org.onebusaway.transit_data.model.service_alerts.NaturalLanguageStringBean) ResponseBean(org.onebusaway.api.model.ResponseBean) Alert(com.google.transit.realtime.GtfsRealtime.Alert) ServiceAlertBean(org.onebusaway.transit_data.model.service_alerts.ServiceAlertBean) FeedEntity(com.google.transit.realtime.GtfsRealtime.FeedEntity) Test(org.junit.Test)

Example 3 with Alert

use of com.google.transit.realtime.GtfsRealtime.Alert in project onebusaway-application-modules by camsys.

the class AlertsForAgencyAction method fillFeedMessage.

@Override
protected void fillFeedMessage(FeedMessage.Builder feed, String agencyId, long timestamp) {
    ListBean<ServiceAlertBean> alerts = _service.getAllServiceAlertsForAgencyId(agencyId);
    for (ServiceAlertBean serviceAlert : alerts.getList()) {
        FeedEntity.Builder entity = feed.addEntityBuilder();
        entity.setId(Integer.toString(feed.getEntityCount()));
        Alert.Builder alert = entity.getAlertBuilder();
        fillTranslations(serviceAlert.getSummaries(), alert.getHeaderTextBuilder());
        fillTranslations(serviceAlert.getDescriptions(), alert.getDescriptionTextBuilder());
        if (serviceAlert.getActiveWindows() != null) {
            for (TimeRangeBean range : serviceAlert.getActiveWindows()) {
                TimeRange.Builder timeRange = alert.addActivePeriodBuilder();
                if (range.getFrom() != 0) {
                    timeRange.setStart(range.getFrom() / 1000);
                }
                if (range.getTo() != 0) {
                    timeRange.setEnd(range.getTo() / 1000);
                }
            }
        }
        if (serviceAlert.getAllAffects() != null) {
            for (SituationAffectsBean affects : serviceAlert.getAllAffects()) {
                EntitySelector.Builder entitySelector = alert.addInformedEntityBuilder();
                if (affects.getAgencyId() != null) {
                    entitySelector.setAgencyId(affects.getAgencyId());
                }
                if (affects.getRouteId() != null) {
                    entitySelector.setRouteId(normalizeId(affects.getRouteId()));
                }
                if (affects.getTripId() != null) {
                    TripDescriptor.Builder trip = entitySelector.getTripBuilder();
                    trip.setTripId(normalizeId(affects.getTripId()));
                    entitySelector.setTrip(trip);
                }
                if (affects.getStopId() != null) {
                    AgencyAndId stopId = modifiedStopId(agencyId, affects.getStopId());
                    if (stopId.getAgencyId().equals(agencyId)) {
                        entitySelector.setStopId(normalizeId(stopId.toString()));
                    }
                }
            }
        }
    }
}
Also used : EntitySelector(com.google.transit.realtime.GtfsRealtime.EntitySelector) AgencyAndId(org.onebusaway.gtfs.model.AgencyAndId) TimeRangeBean(org.onebusaway.transit_data.model.service_alerts.TimeRangeBean) TimeRange(com.google.transit.realtime.GtfsRealtime.TimeRange) SituationAffectsBean(org.onebusaway.transit_data.model.service_alerts.SituationAffectsBean) TripDescriptor(com.google.transit.realtime.GtfsRealtime.TripDescriptor) Alert(com.google.transit.realtime.GtfsRealtime.Alert) ServiceAlertBean(org.onebusaway.transit_data.model.service_alerts.ServiceAlertBean) FeedEntity(com.google.transit.realtime.GtfsRealtime.FeedEntity)

Example 4 with Alert

use of com.google.transit.realtime.GtfsRealtime.Alert in project onebusaway-application-modules by camsys.

the class GtfsRealtimeAlertLibraryTest method testGetAlertAsServiceAlert.

@Test
public void testGetAlertAsServiceAlert() {
    AgencyAndId alertId = new AgencyAndId("1", "A1");
    Alert.Builder alert = Alert.newBuilder();
    GtfsRealtime.TimeRange.Builder timeRange = GtfsRealtime.TimeRange.newBuilder();
    timeRange.setStart(1L);
    timeRange.setStart(2L);
    alert.addActivePeriod(timeRange);
    EntitySelector.Builder entitySelector = EntitySelector.newBuilder();
    entitySelector.setAgencyId("agencyId");
    entitySelector.setRouteId("routeId");
    entitySelector.setStopId("stopId");
    TripDescriptor.Builder tripDescriptor = TripDescriptor.newBuilder();
    tripDescriptor.setTripId("tripId");
    entitySelector.setTrip(tripDescriptor);
    alert.addInformedEntity(entitySelector);
    alert.setCause(Alert.Cause.ACCIDENT);
    alert.setEffect(Alert.Effect.DETOUR);
    TranslatedString.Builder headerTexts = TranslatedString.newBuilder();
    Translation.Builder headerText = Translation.newBuilder();
    headerText.setLanguage("en");
    headerText.setText("Summary");
    headerTexts.addTranslation(headerText);
    alert.setHeaderText(headerTexts);
    TranslatedString.Builder descriptionTexts = TranslatedString.newBuilder();
    Translation.Builder descriptionText = Translation.newBuilder();
    descriptionText.setLanguage("fr");
    descriptionText.setText("Description");
    descriptionTexts.addTranslation(descriptionText);
    alert.setDescriptionText(descriptionTexts);
    TranslatedString.Builder urls = TranslatedString.newBuilder();
    Translation.Builder url = Translation.newBuilder();
    url.setLanguage("es");
    url.setText("http://something/");
    urls.addTranslation(url);
    alert.setUrl(urls);
    Mockito.when(_entitySource.getRouteId("routeId")).thenReturn(ServiceAlertLibrary.id("1", "routeId"));
    Mockito.when(_entitySource.getStopId("stopId")).thenReturn(ServiceAlertLibrary.id("2", "stopId"));
    Mockito.when(_entitySource.getTripId("tripId")).thenReturn(ServiceAlertLibrary.id("3", "tripId"));
    ServiceAlert.Builder serviceAlert = _library.getAlertAsServiceAlert(alertId, alert.build());
    Id id = serviceAlert.getId();
    assertEquals("1", id.getAgencyId());
    assertEquals("A1", id.getId());
    assertEquals(1, serviceAlert.getAffectsCount());
    Affects affects = serviceAlert.getAffects(0);
    assertEquals("agencyId", affects.getAgencyId());
    assertEquals("1", affects.getRouteId().getAgencyId());
    assertEquals("routeId", affects.getRouteId().getId());
    assertEquals("2", affects.getStopId().getAgencyId());
    assertEquals("stopId", affects.getStopId().getId());
    assertEquals("3", affects.getTripId().getAgencyId());
    assertEquals("tripId", affects.getTripId().getId());
    assertEquals(ServiceAlert.Cause.ACCIDENT, serviceAlert.getCause());
    assertEquals(1, serviceAlert.getConsequenceCount());
    Consequence consequence = serviceAlert.getConsequence(0);
    assertEquals(Effect.DETOUR, consequence.getEffect());
    ServiceAlerts.TranslatedString summaries = serviceAlert.getSummary();
    assertEquals(1, summaries.getTranslationCount());
    ServiceAlerts.TranslatedString.Translation summary = summaries.getTranslation(0);
    assertEquals("en", summary.getLanguage());
    assertEquals("Summary", summary.getText());
    ServiceAlerts.TranslatedString descriptions = serviceAlert.getDescription();
    assertEquals(1, descriptions.getTranslationCount());
    ServiceAlerts.TranslatedString.Translation description = descriptions.getTranslation(0);
    assertEquals("fr", description.getLanguage());
    assertEquals("Description", description.getText());
    ServiceAlerts.TranslatedString alertUrls = serviceAlert.getUrl();
    assertEquals(1, alertUrls.getTranslationCount());
    ServiceAlerts.TranslatedString.Translation alertUrl = alertUrls.getTranslation(0);
    assertEquals("es", alertUrl.getLanguage());
    assertEquals("http://something/", alertUrl.getText());
}
Also used : TranslatedString(com.google.transit.realtime.GtfsRealtime.TranslatedString) EntitySelector(com.google.transit.realtime.GtfsRealtime.EntitySelector) Translation(com.google.transit.realtime.GtfsRealtime.TranslatedString.Translation) AgencyAndId(org.onebusaway.gtfs.model.AgencyAndId) ServiceAlerts(org.onebusaway.transit_data_federation.services.service_alerts.ServiceAlerts) Consequence(org.onebusaway.transit_data_federation.services.service_alerts.ServiceAlerts.Consequence) Affects(org.onebusaway.transit_data_federation.services.service_alerts.ServiceAlerts.Affects) ServiceAlert(org.onebusaway.transit_data_federation.services.service_alerts.ServiceAlerts.ServiceAlert) TripDescriptor(com.google.transit.realtime.GtfsRealtime.TripDescriptor) ServiceAlert(org.onebusaway.transit_data_federation.services.service_alerts.ServiceAlerts.ServiceAlert) Alert(com.google.transit.realtime.GtfsRealtime.Alert) Id(org.onebusaway.transit_data_federation.services.service_alerts.ServiceAlerts.Id) AgencyAndId(org.onebusaway.gtfs.model.AgencyAndId) Test(org.junit.Test)

Example 5 with Alert

use of com.google.transit.realtime.GtfsRealtime.Alert in project onebusaway-application-modules by camsys.

the class GtfsRealtimeSource method handleAlerts.

private void handleAlerts(FeedMessage alerts) {
    for (FeedEntity entity : alerts.getEntityList()) {
        Alert alert = entity.getAlert();
        if (alert == null) {
            _log.warn("epxected a FeedEntity with an Alert");
            continue;
        }
        AgencyAndId id = createId(entity.getId());
        if (entity.getIsDeleted()) {
            _alertsById.remove(id);
            _serviceAlertService.removeServiceAlert(id);
        } else {
            ServiceAlert.Builder serviceAlertBuilder = _alertLibrary.getAlertAsServiceAlert(id, alert, _alertAgencyIdMap);
            ServiceAlert serviceAlert = serviceAlertBuilder.build();
            ServiceAlert existingAlert = _alertsById.get(id);
            if (existingAlert == null || !existingAlert.equals(serviceAlert)) {
                _alertsById.put(id, serviceAlert);
                ServiceAlertRecord serviceAlertRecord = new ServiceAlertRecord();
                serviceAlertRecord.setAgencyId(_agencyIds.get(0));
                serviceAlertRecord.setActiveWindows(new HashSet<ServiceAlertTimeRange>());
                if (serviceAlert.getActiveWindowList() != null) {
                    for (ServiceAlerts.TimeRange timeRange : serviceAlert.getActiveWindowList()) {
                        ServiceAlertTimeRange serviceAlertTimeRange = new ServiceAlertTimeRange();
                        serviceAlertTimeRange.setFromValue(timeRange.getStart());
                        serviceAlertTimeRange.setToValue(timeRange.getEnd());
                        serviceAlertRecord.getActiveWindows().add(serviceAlertTimeRange);
                    }
                }
                serviceAlertRecord.setAllAffects(new HashSet<ServiceAlertsSituationAffectsClause>());
                if (serviceAlert.getAffectsList() != null) {
                    for (ServiceAlerts.Affects affects : serviceAlertBuilder.getAffectsList()) {
                        ServiceAlertsSituationAffectsClause serviceAlertsSituationAffectsClause = new ServiceAlertsSituationAffectsClause();
                        serviceAlertsSituationAffectsClause.setAgencyId(affects.getAgencyId());
                        serviceAlertsSituationAffectsClause.setApplicationId(affects.getApplicationId());
                        serviceAlertsSituationAffectsClause.setDirectionId(affects.getDirectionId());
                        serviceAlertsSituationAffectsClause.setRouteId(affects.getRouteId().getId());
                        serviceAlertsSituationAffectsClause.setStopId(affects.getStopId().getId());
                        serviceAlertsSituationAffectsClause.setTripId(affects.getTripId().getId());
                        serviceAlertRecord.getAllAffects().add(serviceAlertsSituationAffectsClause);
                    }
                }
                serviceAlertRecord.setCause(getECause(serviceAlert.getCause()));
                serviceAlertRecord.setConsequences(new HashSet<ServiceAlertSituationConsequenceClause>());
                if (serviceAlert.getConsequenceList() != null) {
                    for (ServiceAlerts.Consequence consequence : serviceAlert.getConsequenceList()) {
                        ServiceAlertSituationConsequenceClause serviceAlertSituationConsequenceClause = new ServiceAlertSituationConsequenceClause();
                        serviceAlertSituationConsequenceClause.setDetourPath(consequence.getDetourPath());
                        serviceAlertSituationConsequenceClause.setDetourStopIds(new HashSet<String>());
                        if (consequence.getDetourStopIdsList() != null) {
                            for (ServiceAlerts.Id stopId : consequence.getDetourStopIdsList()) {
                                serviceAlertSituationConsequenceClause.getDetourStopIds().add(stopId.getId());
                            }
                        }
                        serviceAlertRecord.getConsequences().add(serviceAlertSituationConsequenceClause);
                    }
                }
                serviceAlertRecord.setCreationTime(serviceAlert.getCreationTime());
                serviceAlertRecord.setDescriptions(new HashSet<ServiceAlertLocalizedString>());
                if (serviceAlert.getDescription() != null) {
                    for (ServiceAlerts.TranslatedString.Translation translation : serviceAlert.getDescription().getTranslationList()) {
                        ServiceAlertLocalizedString string = new ServiceAlertLocalizedString();
                        string.setValue(translation.getText());
                        string.setLanguage(translation.getLanguage());
                        serviceAlertRecord.getDescriptions().add(string);
                    }
                }
                serviceAlertRecord.setModifiedTime(serviceAlert.getModifiedTime());
                serviceAlertRecord.setPublicationWindows(new HashSet<ServiceAlertTimeRange>());
                serviceAlertRecord.setServiceAlertId(serviceAlert.getId().getId());
                serviceAlertRecord.setSeverity(getESeverity(serviceAlert.getSeverity()));
                serviceAlertRecord.setSummaries(new HashSet<ServiceAlertLocalizedString>());
                if (serviceAlert.getSummary() != null) {
                    for (ServiceAlerts.TranslatedString.Translation translation : serviceAlert.getSummary().getTranslationList()) {
                        ServiceAlertLocalizedString string = new ServiceAlertLocalizedString();
                        string.setValue(translation.getText());
                        string.setLanguage(translation.getLanguage());
                        serviceAlertRecord.getSummaries().add(string);
                    }
                }
                serviceAlertRecord.setUrls(new HashSet<ServiceAlertLocalizedString>());
                if (serviceAlert.getUrl() != null) {
                    for (ServiceAlerts.TranslatedString.Translation translation : serviceAlert.getUrl().getTranslationList()) {
                        ServiceAlertLocalizedString string = new ServiceAlertLocalizedString();
                        string.setValue(translation.getText());
                        string.setLanguage(translation.getLanguage());
                        serviceAlertRecord.getUrls().add(string);
                    }
                }
                _serviceAlertService.createOrUpdateServiceAlert(serviceAlertRecord);
            }
        }
    }
}
Also used : ServiceAlertsSituationAffectsClause(org.onebusaway.transit_data_federation.impl.service_alerts.ServiceAlertsSituationAffectsClause) AgencyAndId(org.onebusaway.gtfs.model.AgencyAndId) ServiceAlerts(org.onebusaway.transit_data_federation.services.service_alerts.ServiceAlerts) ServiceAlertLocalizedString(org.onebusaway.transit_data_federation.impl.service_alerts.ServiceAlertLocalizedString) ServiceAlertRecord(org.onebusaway.transit_data_federation.impl.service_alerts.ServiceAlertRecord) ServiceAlertTimeRange(org.onebusaway.transit_data_federation.impl.service_alerts.ServiceAlertTimeRange) ServiceAlertLocalizedString(org.onebusaway.transit_data_federation.impl.service_alerts.ServiceAlertLocalizedString) ServiceAlert(org.onebusaway.transit_data_federation.services.service_alerts.ServiceAlerts.ServiceAlert) ServiceAlert(org.onebusaway.transit_data_federation.services.service_alerts.ServiceAlerts.ServiceAlert) Alert(com.google.transit.realtime.GtfsRealtime.Alert) FeedEntity(com.google.transit.realtime.GtfsRealtime.FeedEntity) ServiceAlertSituationConsequenceClause(org.onebusaway.transit_data_federation.impl.service_alerts.ServiceAlertSituationConsequenceClause)

Aggregations

Alert (com.google.transit.realtime.GtfsRealtime.Alert)5 EntitySelector (com.google.transit.realtime.GtfsRealtime.EntitySelector)4 FeedEntity (com.google.transit.realtime.GtfsRealtime.FeedEntity)3 TimeRange (com.google.transit.realtime.GtfsRealtime.TimeRange)3 AgencyAndId (org.onebusaway.gtfs.model.AgencyAndId)3 TranslatedString (com.google.transit.realtime.GtfsRealtime.TranslatedString)2 Translation (com.google.transit.realtime.GtfsRealtime.TranslatedString.Translation)2 TripDescriptor (com.google.transit.realtime.GtfsRealtime.TripDescriptor)2 Date (java.util.Date)2 Test (org.junit.Test)2 ServiceAlertBean (org.onebusaway.transit_data.model.service_alerts.ServiceAlertBean)2 SituationAffectsBean (org.onebusaway.transit_data.model.service_alerts.SituationAffectsBean)2 TimeRangeBean (org.onebusaway.transit_data.model.service_alerts.TimeRangeBean)2 ServiceAlerts (org.onebusaway.transit_data_federation.services.service_alerts.ServiceAlerts)2 ServiceAlert (org.onebusaway.transit_data_federation.services.service_alerts.ServiceAlerts.ServiceAlert)2 FeedMessage (com.google.transit.realtime.GtfsRealtime.FeedMessage)1 ArrayList (java.util.ArrayList)1 ResponseBean (org.onebusaway.api.model.ResponseBean)1 AlertModel (org.onebusaway.gtfs_realtime.model.AlertModel)1 EntitySelectorModel (org.onebusaway.gtfs_realtime.model.EntitySelectorModel)1