@tmlmobilidade/types
Version:
49 lines (48 loc) • 2.41 kB
TypeScript
import { z } from 'zod';
/**
* Represents a route in the GTFS (General Transit Feed Specification) format.
* A route is a group of trips that operate on a specific path or service,
* typically identified by a unique route ID. Each route can have various attributes
* such as agency ID, route color, long name, short name, and type of service.
*/
export declare const GtfsRouteSchema: z.ZodObject<{
agency_id: z.ZodOptional<z.ZodNullable<z.ZodString>>;
continuous_drop_off: z.ZodOptional<z.ZodNullable<z.ZodUnion<[z.ZodLiteral<0>, z.ZodLiteral<1>, z.ZodLiteral<2>, z.ZodLiteral<3>]>>>;
continuous_pickup: z.ZodOptional<z.ZodNullable<z.ZodUnion<[z.ZodLiteral<0>, z.ZodLiteral<1>, z.ZodLiteral<2>, z.ZodLiteral<3>]>>>;
route_color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
route_desc: z.ZodOptional<z.ZodNullable<z.ZodString>>;
route_id: z.ZodString;
route_long_name: z.ZodString;
route_short_name: z.ZodString;
route_sort_order: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
route_text_color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
route_type: z.ZodEnum<["0", "1", "2", "3", "4", "5", "6", "7", "11", "12"]>;
route_url: z.ZodOptional<z.ZodNullable<z.ZodString>>;
}, "strip", z.ZodTypeAny, {
route_id: string;
route_long_name: string;
route_short_name: string;
route_type: "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "11" | "12";
agency_id?: string | null | undefined;
continuous_drop_off?: 0 | 1 | 2 | 3 | null | undefined;
continuous_pickup?: 0 | 1 | 2 | 3 | null | undefined;
route_color?: string | null | undefined;
route_desc?: string | null | undefined;
route_sort_order?: number | null | undefined;
route_text_color?: string | null | undefined;
route_url?: string | null | undefined;
}, {
route_id: string;
route_long_name: string;
route_short_name: string;
route_type: "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "11" | "12";
agency_id?: string | null | undefined;
continuous_drop_off?: 0 | 1 | 2 | 3 | null | undefined;
continuous_pickup?: 0 | 1 | 2 | 3 | null | undefined;
route_color?: string | null | undefined;
route_desc?: string | null | undefined;
route_sort_order?: number | null | undefined;
route_text_color?: string | null | undefined;
route_url?: string | null | undefined;
}>;
export type GtfsRoute = z.infer<typeof GtfsRouteSchema>;