UNPKG

s2-tools

Version:

A collection of geospatial tools primarily designed for WGS84, Web Mercator, and S2.

123 lines 5.45 kB
import { GTFSRealtimeEntitySelector, GTFSRealtimeTranslatedString } from '.'; import type { Pbf as Protobuf } from '../..'; /** Severity of this alert. */ export declare enum GTFSRealtimeSeverityLevel { UNKNOWN_SEVERITY = 1, INFO = 2, WARNING = 3, SEVERE = 4 } /** * What is the effect of this problem on the affected entity. If effect_detail is included, then * Effect must also be included. */ export declare enum GTFSRealtimeEffect { NO_SERVICE = 1, REDUCED_SERVICE = 2, SIGNIFICANT_DELAYS = 3, DETOUR = 4, ADDITIONAL_SERVICE = 5, MODIFIED_SERVICE = 6, OTHER_EFFECT = 7, UNKNOWN_EFFECT = 8, STOP_MOVED = 9, NO_EFFECT = 10, ACCESSIBILITY_ISSUE = 11 } /** Cause of this alert. If cause_detail is included, then Cause must also be included. */ export declare enum GTFSRealtimeCause { UNKNOWN_CAUSE = 1, OTHER_CAUSE = 2,// Not machine-representable. TECHNICAL_PROBLEM = 3, STRIKE = 4,// Public transit agency employees stopped working. DEMONSTRATION = 5,// People are blocking the streets. ACCIDENT = 6, HOLIDAY = 7, WEATHER = 8, MAINTENANCE = 9, CONSTRUCTION = 10, POLICE_ACTIVITY = 11, MEDICAL_EMERGENCY = 12 } /** An alert, indicating some sort of incident in the public transit network. */ export declare class GTFSRealtimeAlert { #private; /** * Time when the alert should be shown to the user. If missing, the * alert will be shown as long as it appears in the feed. * If multiple ranges are given, the alert will be shown during all of them. */ activePeriods: GTFSRealtimeTimeRange[]; /** Entities whose users we should notify of this alert. */ informedEntities: GTFSRealtimeEntitySelector[]; /** Cause of this alert. If cause_detail is included, then Cause must also be included. */ cause: GTFSRealtimeCause; /** * What is the effect of this problem on the affected entity. If effect_detail is included, then * Effect must also be included. */ effect: GTFSRealtimeEffect; /** The URL which provides additional information about the alert. */ url?: GTFSRealtimeTranslatedString; /** Alert header. Contains a short summary of the alert text as plain-text. */ headerText?: GTFSRealtimeTranslatedString; /** * Full description for the alert as plain-text. The information in the * description should add to the information of the header. */ descriptionText?: GTFSRealtimeTranslatedString; /** * Text for alert header to be used in text-to-speech implementations. This field is the * text-to-speech version of header_text. */ ttsHeaderText?: GTFSRealtimeTranslatedString; /** * Text for full description for the alert to be used in text-to-speech implementations. * This field is the text-to-speech version of description_text. */ ttsDescriptionText?: GTFSRealtimeTranslatedString; /** Severity of this alert. */ severityLevel: GTFSRealtimeSeverityLevel; /** * TranslatedImage to be displayed along the alert text. Used to explain visually the alert effect of a detour, station closure, etc. The image must enhance the understanding of the alert. Any essential information communicated within the image must also be contained in the alert text. * The following types of images are discouraged : image containing mainly text, marketing or branded images that add no additional information. * NOTE: This field is still experimental, and subject to change. It may be formally adopted in the future. */ image?: GTFSRealtimeTranslatedString; /** * Text describing the appearance of the linked image in the `image` field (e.g., in case the image can't be displayed * or the user can't see the image for accessibility reasons). See the HTML spec for alt image text - https://html.spec.whatwg.org/#alt. * NOTE: This field is still experimental, and subject to change. It may be formally adopted in the future */ imageAlternativeText?: GTFSRealtimeTranslatedString; /** * Description of the cause of the alert that allows for agency-specific language; more specific than the Cause. If cause_detail is included, then Cause must also be included. * NOTE: This field is still experimental, and subject to change. It may be formally adopted in the future. */ causeDetail?: GTFSRealtimeTranslatedString; /** * Description of the effect of the alert that allows for agency-specific language; more specific than the Effect. If effect_detail is included, then Effect must also be included. * NOTE: This field is still experimental, and subject to change. It may be formally adopted in the future. */ effectDetail?: GTFSRealtimeTranslatedString; /** * @param pbf - The Protobuf object to read from * @param end - The end position of the message in the buffer */ constructor(pbf: Protobuf, end: number); } /** * A time interval. The interval is considered active at time 't' if 't' is * greater than or equal to the start time and less than the end time. */ export declare class GTFSRealtimeTimeRange { #private; start?: Date; end?: Date; /** * @param pbf - The Protobuf object to read from * @param end - The end position of the message in the buffer */ constructor(pbf: Protobuf, end: number); } //# sourceMappingURL=alert.d.ts.map