db

package
v0.6.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 8, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Agency

type Agency struct {
	Pk       int64
	ID       string
	SystemPk int64
	Name     string
	Url      string
	Timezone string
	Language pgtype.Text
	Phone    pgtype.Text
	FareUrl  pgtype.Text
	Email    pgtype.Text
	FeedPk   int64
}

type Alert

type Alert struct {
	Pk          int64
	ID          string
	SystemPk    int64
	Cause       string
	Effect      string
	Header      string
	Description string
	Url         string
	Hash        string
	FeedPk      int64
}

type AlertActivePeriod

type AlertActivePeriod struct {
	Pk       int64
	AlertPk  int64
	StartsAt pgtype.Timestamptz
	EndsAt   pgtype.Timestamptz
}

type AlertAgency

type AlertAgency struct {
	AlertPk  int64
	AgencyPk int64
}

type AlertRoute

type AlertRoute struct {
	AlertPk int64
	RoutePk int64
}

type AlertStop

type AlertStop struct {
	AlertPk int64
	StopPk  int64
}

type AlertTrip

type AlertTrip struct {
	AlertPk int64
	TripPk  int64
}

type DBTX

type DBTX interface {
	Exec(context.Context, string, ...interface{}) (pgconn.CommandTag, error)
	Query(context.Context, string, ...interface{}) (pgx.Rows, error)
	QueryRow(context.Context, string, ...interface{}) pgx.Row
	CopyFrom(ctx context.Context, tableName pgx.Identifier, columnNames []string, rowSrc pgx.CopyFromSource) (int64, error)
	SendBatch(context.Context, *pgx.Batch) pgx.BatchResults
}

type DeleteServiceMapParams

type DeleteServiceMapParams struct {
	ConfigPk int64
	RoutePk  int64
}

type DeleteStaleAgenciesParams

type DeleteStaleAgenciesParams struct {
	FeedPk           int64
	UpdatedAgencyPks []int64
}

type DeleteStaleAlertsParams

type DeleteStaleAlertsParams struct {
	FeedPk          int64
	UpdatedAlertPks []int64
}

type DeleteStaleRoutesParams

type DeleteStaleRoutesParams struct {
	FeedPk          int64
	UpdatedRoutePks []int64
}

type DeleteStaleStopsParams

type DeleteStaleStopsParams struct {
	FeedPk         int64
	UpdatedStopPks []int64
}

type DeleteStaleTripsParams

type DeleteStaleTripsParams struct {
	FeedPk         int64
	UpdatedTripPks []int64
}

type DeleteStaleVehiclesParams

type DeleteStaleVehiclesParams struct {
	FeedPk           int64
	ActiveVehicleIds []string
}

type EstimateHeadwaysForRoutesParams

type EstimateHeadwaysForRoutesParams struct {
	RoutePks    []int64
	PresentTime pgtype.Timestamptz
}

type EstimateHeadwaysForRoutesRow

type EstimateHeadwaysForRoutesRow struct {
	RoutePk          int64
	EstimatedHeadway int32
}

type Feed

type Feed struct {
	Pk                   int64
	ID                   string
	SystemPk             int64
	Config               string
	LastContentHash      pgtype.Text
	LastUpdate           pgtype.Timestamptz
	LastSuccessfulUpdate pgtype.Timestamptz
	LastSkippedUpdate    pgtype.Timestamptz
	LastFailedUpdate     pgtype.Timestamptz
}

type GetAgencyParams

type GetAgencyParams struct {
	SystemPk int64
	AgencyID string
}

type GetAlertInSystemParams

type GetAlertInSystemParams struct {
	SystemPk int64
	AlertID  string
}

type GetDestinationsForTripsRow

type GetDestinationsForTripsRow struct {
	TripPk        int64
	DestinationPk int64
}

type GetFeedParams

type GetFeedParams struct {
	SystemID string
	FeedID   string
}

type GetRouteParams

type GetRouteParams struct {
	SystemPk int64
	RouteID  string
}

type GetStopParams

type GetStopParams struct {
	SystemID string
	StopID   string
}

type GetTripParams

type GetTripParams struct {
	TripID  string
	RoutePk int64
}

type GetTripRow

type GetTripRow struct {
	Pk               int64
	ID               string
	RoutePk          int64
	DirectionID      pgtype.Bool
	StartedAt        pgtype.Timestamptz
	GtfsHash         string
	FeedPk           int64
	VehicleID        pgtype.Text
	VehicleLatitude  pgtype.Numeric
	VehicleLongitude pgtype.Numeric
	VehicleBearing   pgtype.Float4
	VehicleUpdatedAt pgtype.Timestamptz
}

type GetVehicleParams

type GetVehicleParams struct {
	SystemPk  int64
	VehicleID pgtype.Text
}

type GetVehicleRow

type GetVehicleRow struct {
	Pk                  int64
	ID                  pgtype.Text
	SystemPk            int64
	TripPk              pgtype.Int8
	Label               pgtype.Text
	LicensePlate        pgtype.Text
	CurrentStatus       pgtype.Text
	Latitude            pgtype.Numeric
	Longitude           pgtype.Numeric
	Bearing             pgtype.Float4
	Odometer            pgtype.Float8
	Speed               pgtype.Float4
	CongestionLevel     string
	UpdatedAt           pgtype.Timestamptz
	CurrentStopPk       pgtype.Int8
	CurrentStopSequence pgtype.Int4
	OccupancyStatus     pgtype.Text
	FeedPk              int64
	OccupancyPercentage pgtype.Int4
	StopID              pgtype.Text
	StopName            pgtype.Text
	TripID              pgtype.Text
	TripDirectionID     pgtype.Bool
	RouteID             pgtype.Text
	RouteColor          pgtype.Text
}

type InsertAgencyParams

type InsertAgencyParams struct {
	ID       string
	SystemPk int64
	FeedPk   int64
	Name     string
	Url      string
	Timezone string
	Language pgtype.Text
	Phone    pgtype.Text
	FareUrl  pgtype.Text
	Email    pgtype.Text
}

type InsertAlertActivePeriodParams

type InsertAlertActivePeriodParams struct {
	AlertPk  int64
	StartsAt pgtype.Timestamptz
	EndsAt   pgtype.Timestamptz
}

type InsertAlertAgencyParams

type InsertAlertAgencyParams struct {
	AlertPk  int64
	AgencyPk int64
}

type InsertAlertParams

type InsertAlertParams struct {
	ID          string
	SystemPk    int64
	FeedPk      int64
	Cause       string
	Effect      string
	Header      string
	Description string
	Url         string
	Hash        string
}

type InsertAlertRouteParams

type InsertAlertRouteParams struct {
	AlertPk int64
	RoutePk int64
}

type InsertAlertStopParams

type InsertAlertStopParams struct {
	AlertPk int64
	StopPk  int64
}

type InsertFeedParams

type InsertFeedParams struct {
	ID       string
	SystemPk int64
	Config   string
}

type InsertRouteParams

type InsertRouteParams struct {
	ID                string
	SystemPk          int64
	FeedPk            int64
	Color             string
	TextColor         string
	ShortName         pgtype.Text
	LongName          pgtype.Text
	Description       pgtype.Text
	Url               pgtype.Text
	SortOrder         pgtype.Int4
	Type              string
	ContinuousPickup  string
	ContinuousDropOff string
	AgencyPk          int64
}

type InsertServiceMapConfigParams

type InsertServiceMapConfigParams struct {
	ID       string
	SystemPk int64
	Config   []byte
}

type InsertServiceMapParams

type InsertServiceMapParams struct {
	ConfigPk int64
	RoutePk  int64
}

type InsertServiceMapStopParams

type InsertServiceMapStopParams struct {
	MapPk    int64
	StopPk   int64
	Position int32
}

type InsertStopHeadSignRuleParams

type InsertStopHeadSignRuleParams struct {
	FeedPk   int64
	Priority int32
	StopPk   int64
	Track    pgtype.Text
	Headsign string
}

type InsertStopParams

type InsertStopParams struct {
	ID                 string
	SystemPk           int64
	FeedPk             int64
	Name               pgtype.Text
	Longitude          pgtype.Numeric
	Latitude           pgtype.Numeric
	Url                pgtype.Text
	Code               pgtype.Text
	Description        pgtype.Text
	PlatformCode       pgtype.Text
	Timezone           pgtype.Text
	Type               string
	WheelchairBoarding pgtype.Bool
	ZoneID             pgtype.Text
}

type InsertSystemParams

type InsertSystemParams struct {
	ID     string
	Name   string
	Status string
}

type InsertTransferParams

type InsertTransferParams struct {
	SystemPk        pgtype.Int8
	FeedPk          int64
	FromStopPk      int64
	ToStopPk        int64
	Type            string
	MinTransferTime pgtype.Int4
}

type InsertTripParams

type InsertTripParams struct {
	ID          string
	RoutePk     int64
	FeedPk      int64
	DirectionID pgtype.Bool
	StartedAt   pgtype.Timestamptz
	GtfsHash    string
}

type InsertTripStopTimeParams

type InsertTripStopTimeParams struct {
	StopPk               int64
	TripPk               int64
	ArrivalTime          pgtype.Timestamptz
	ArrivalDelay         pgtype.Int4
	ArrivalUncertainty   pgtype.Int4
	DepartureTime        pgtype.Timestamptz
	DepartureDelay       pgtype.Int4
	DepartureUncertainty pgtype.Int4
	StopSequence         int32
	Track                pgtype.Text
	Headsign             pgtype.Text
	Past                 bool
}

type InsertVehicleParams

type InsertVehicleParams struct {
	ID                  pgtype.Text
	SystemPk            int64
	TripPk              pgtype.Int8
	Label               pgtype.Text
	LicensePlate        pgtype.Text
	CurrentStatus       pgtype.Text
	Latitude            pgtype.Numeric
	Longitude           pgtype.Numeric
	Bearing             pgtype.Float4
	Odometer            pgtype.Float8
	Speed               pgtype.Float4
	CongestionLevel     string
	UpdatedAt           pgtype.Timestamptz
	CurrentStopPk       pgtype.Int8
	CurrentStopSequence pgtype.Int4
	OccupancyStatus     pgtype.Text
	FeedPk              int64
	OccupancyPercentage pgtype.Int4
}

type ListActiveAlertsForAgenciesParams

type ListActiveAlertsForAgenciesParams struct {
	AgencyPks   []int64
	PresentTime pgtype.Timestamptz
}

type ListActiveAlertsForAgenciesRow

type ListActiveAlertsForAgenciesRow struct {
	ID     string
	Cause  string
	Effect string
}

type ListActiveAlertsForRoutesParams

type ListActiveAlertsForRoutesParams struct {
	RoutePks    []int64
	PresentTime pgtype.Timestamptz
}

type ListActiveAlertsForRoutesRow

type ListActiveAlertsForRoutesRow struct {
	RoutePk int64
	ID      string
	Cause   string
	Effect  string
}

type ListActiveAlertsForStopsParams

type ListActiveAlertsForStopsParams struct {
	StopPks     []int64
	PresentTime pgtype.Timestamptz
}

type ListActiveAlertsForStopsRow

type ListActiveAlertsForStopsRow struct {
	StopPk   int64
	Pk       int64
	ID       string
	Cause    string
	Effect   string
	StartsAt pgtype.Timestamptz
	EndsAt   pgtype.Timestamptz
}

type ListActivePeriodsForAlertsRow

type ListActivePeriodsForAlertsRow struct {
	Pk       int64
	StartsAt pgtype.Timestamptz
	EndsAt   pgtype.Timestamptz
}

type ListAlertPksAndHashesParams

type ListAlertPksAndHashesParams struct {
	AlertIds []string
	SystemPk int64
}

type ListAlertPksAndHashesRow

type ListAlertPksAndHashesRow struct {
	ID   string
	Pk   int64
	Hash string
}

type ListAlertsInSystemAndByIDsParams

type ListAlertsInSystemAndByIDsParams struct {
	SystemPk int64
	Ids      []string
}

type ListRoutesByPkRow

type ListRoutesByPkRow struct {
	Pk       int64
	ID       string
	Color    string
	SystemID string
}

type ListRoutesInAgencyRow

type ListRoutesInAgencyRow struct {
	ID    string
	Color string
}

type ListServiceMapsConfigIDsForStopsRow

type ListServiceMapsConfigIDsForStopsRow struct {
	Pk int64
	ID string
}

type ListServiceMapsForRoutesRow

type ListServiceMapsForRoutesRow struct {
	RoutePk  int64
	ConfigID string
	Position pgtype.Int4
	StopID   pgtype.Text
	StopName pgtype.Text
}

type ListServiceMapsForStopsRow

type ListServiceMapsForStopsRow struct {
	StopPk   int64
	ConfigID string
	RoutePk  int64
}

type ListStopPksForRealtimeMapRow

type ListStopPksForRealtimeMapRow struct {
	TripPk      int64
	DirectionID pgtype.Bool
	StopPk      int64
}

type ListStopsByPkRow

type ListStopsByPkRow struct {
	Pk       int64
	StopID   string
	Name     pgtype.Text
	SystemID string
}

type ListStopsParams

type ListStopsParams struct {
	SystemPk               int64
	FirstStopID            string
	OnlyReturnSpecifiedIds bool
	StopIds                []string
	NumStops               int32
}

type ListStopsTimesForTripRow

type ListStopsTimesForTripRow struct {
	Pk                   int64
	StopPk               int64
	TripPk               int64
	ArrivalTime          pgtype.Timestamptz
	ArrivalDelay         pgtype.Int4
	ArrivalUncertainty   pgtype.Int4
	DepartureTime        pgtype.Timestamptz
	DepartureDelay       pgtype.Int4
	DepartureUncertainty pgtype.Int4
	StopSequence         int32
	Track                pgtype.Text
	Headsign             pgtype.Text
	Past                 bool
	StopID               string
	StopName             pgtype.Text
}

type ListStops_GeographicParams

type ListStops_GeographicParams struct {
	MaxDistance pgtype.Numeric
	MaxResults  int32
	Latitude    pgtype.Numeric
	Longitude   pgtype.Numeric
	SystemPk    int64
}

type ListTransfersInSystemRow

type ListTransfersInSystemRow struct {
	Pk              int64
	SystemPk        pgtype.Int8
	FromStopPk      int64
	ToStopPk        int64
	Type            string
	MinTransferTime pgtype.Int4
	Distance        pgtype.Int4
	FeedPk          int64
	FromStopID      string
	FromStopName    pgtype.Text
	FromSystemID    string
	ToStopID        string
	ToStopName      pgtype.Text
	ToSystemID      string
}

type ListTripPksInSystemParams

type ListTripPksInSystemParams struct {
	TripIds  []string
	SystemPk int64
}

type ListTripPksInSystemRow

type ListTripPksInSystemRow struct {
	ID string
	Pk int64
}

type ListTripStopTimesByStopsRow

type ListTripStopTimesByStopsRow struct {
	Pk                   int64
	StopPk               int64
	TripPk               int64
	ArrivalTime          pgtype.Timestamptz
	ArrivalDelay         pgtype.Int4
	ArrivalUncertainty   pgtype.Int4
	DepartureTime        pgtype.Timestamptz
	DepartureDelay       pgtype.Int4
	DepartureUncertainty pgtype.Int4
	StopSequence         int32
	Track                pgtype.Text
	Headsign             pgtype.Text
	Past                 bool
	Pk_2                 int64
	ID                   string
	RoutePk              int64
	DirectionID          pgtype.Bool
	StartedAt            pgtype.Timestamptz
	GtfsHash             string
	FeedPk               int64
	VehicleID            pgtype.Text
	VehicleLatitude      pgtype.Numeric
	VehicleLongitude     pgtype.Numeric
	VehicleBearing       pgtype.Float4
	VehicleUpdatedAt     pgtype.Timestamptz
}

type ListTripStopTimesForUpdateRow

type ListTripStopTimesForUpdateRow struct {
	Pk           int64
	TripPk       int64
	StopPk       int64
	StopSequence int32
	Past         bool
}

type ListTripsRow

type ListTripsRow struct {
	Pk               int64
	ID               string
	RoutePk          int64
	DirectionID      pgtype.Bool
	StartedAt        pgtype.Timestamptz
	GtfsHash         string
	FeedPk           int64
	VehicleID        pgtype.Text
	VehicleLatitude  pgtype.Numeric
	VehicleLongitude pgtype.Numeric
	VehicleBearing   pgtype.Float4
	VehicleUpdatedAt pgtype.Timestamptz
}

type ListVehicleUniqueColumnsParams

type ListVehicleUniqueColumnsParams struct {
	VehicleIds []string
	SystemPk   int64
}

type ListVehicleUniqueColumnsRow

type ListVehicleUniqueColumnsRow struct {
	ID     pgtype.Text
	Pk     int64
	TripPk pgtype.Int8
}

type ListVehiclesParams

type ListVehiclesParams struct {
	SystemPk               int64
	FirstVehicleID         pgtype.Text
	OnlyReturnSpecifiedIds bool
	VehicleIds             []string
	NumVehicles            int32
}

type ListVehiclesRow

type ListVehiclesRow struct {
	Pk                  int64
	ID                  pgtype.Text
	SystemPk            int64
	TripPk              pgtype.Int8
	Label               pgtype.Text
	LicensePlate        pgtype.Text
	CurrentStatus       pgtype.Text
	Latitude            pgtype.Numeric
	Longitude           pgtype.Numeric
	Bearing             pgtype.Float4
	Odometer            pgtype.Float8
	Speed               pgtype.Float4
	CongestionLevel     string
	UpdatedAt           pgtype.Timestamptz
	CurrentStopPk       pgtype.Int8
	CurrentStopSequence pgtype.Int4
	OccupancyStatus     pgtype.Text
	FeedPk              int64
	OccupancyPercentage pgtype.Int4
	StopID              pgtype.Text
	StopName            pgtype.Text
	TripID              pgtype.Text
	TripDirectionID     pgtype.Bool
	RouteID             pgtype.Text
	RouteColor          pgtype.Text
}

type ListVehicles_GeographicParams

type ListVehicles_GeographicParams struct {
	MaxDistance pgtype.Numeric
	NumVehicles int32
	Latitude    pgtype.Numeric
	Longitude   pgtype.Numeric
	SystemPk    int64
}

type ListVehicles_GeographicRow

type ListVehicles_GeographicRow struct {
	Pk                  int64
	ID                  pgtype.Text
	SystemPk            int64
	TripPk              pgtype.Int8
	Label               pgtype.Text
	LicensePlate        pgtype.Text
	CurrentStatus       pgtype.Text
	Latitude            pgtype.Numeric
	Longitude           pgtype.Numeric
	Bearing             pgtype.Float4
	Odometer            pgtype.Float8
	Speed               pgtype.Float4
	CongestionLevel     string
	UpdatedAt           pgtype.Timestamptz
	CurrentStopPk       pgtype.Int8
	CurrentStopSequence pgtype.Int4
	OccupancyStatus     pgtype.Text
	FeedPk              int64
	OccupancyPercentage pgtype.Int4
	StopID              pgtype.Text
	StopName            pgtype.Text
	TripID              pgtype.Text
	TripDirectionID     pgtype.Bool
	RouteID             pgtype.Text
	RouteColor          pgtype.Text
}

type MapAgencyPkToIdRow

type MapAgencyPkToIdRow struct {
	Pk int64
	ID string
}

type MapRouteIDToPkInSystemParams

type MapRouteIDToPkInSystemParams struct {
	SystemPk        int64
	FilterByRouteID bool
	RouteIds        []string
}

type MapRouteIDToPkInSystemRow

type MapRouteIDToPkInSystemRow struct {
	Pk int64
	ID string
}

type MapStopIDAndPkToStationPkParams

type MapStopIDAndPkToStationPkParams struct {
	SystemPk       int64
	FilterByStopPk bool
	StopPks        []int64
}

type MapStopIDAndPkToStationPkRow

type MapStopIDAndPkToStationPkRow struct {
	StopID    string
	StopPk    int64
	StationPk int64
}

type MapStopIDToPkParams

type MapStopIDToPkParams struct {
	SystemPk       int64
	FilterByStopID bool
	StopIds        []string
}

type MapStopIDToPkRow

type MapStopIDToPkRow struct {
	Pk int64
	ID string
}

type MapStopPkToChildPksRow

type MapStopPkToChildPksRow struct {
	ParentPk pgtype.Int8
	ChildPk  int64
}

type MapStopPkToDescendentPksRow

type MapStopPkToDescendentPksRow struct {
	RootStopPk       int64
	DescendentStopPk int64
}

type MapTripIDToPkInSystemParams

type MapTripIDToPkInSystemParams struct {
	TripIds  []string
	SystemPk int64
}

type MapTripIDToPkInSystemRow

type MapTripIDToPkInSystemRow struct {
	ID string
	Pk int64
}

type MarkFailedUpdateParams

type MarkFailedUpdateParams struct {
	UpdateTime pgtype.Timestamptz
	FeedPk     int64
}

type MarkSkippedUpdateParams

type MarkSkippedUpdateParams struct {
	UpdateTime pgtype.Timestamptz
	FeedPk     int64
}

type MarkSuccessfulUpdateParams

type MarkSuccessfulUpdateParams struct {
	ContentHash pgtype.Text
	UpdateTime  pgtype.Timestamptz
	FeedPk      int64
}

type MarkTripStopTimesPastBatchResults

type MarkTripStopTimesPastBatchResults struct {
	// contains filtered or unexported fields
}

func (*MarkTripStopTimesPastBatchResults) Close

func (*MarkTripStopTimesPastBatchResults) Exec

func (b *MarkTripStopTimesPastBatchResults) Exec(f func(int, error))

type MarkTripStopTimesPastParams

type MarkTripStopTimesPastParams struct {
	TripPk              int64
	CurrentStopSequence int32
}

type Querier

type Querier interface {
	CountAgenciesInSystem(ctx context.Context, systemPk int64) (int64, error)
	CountFeedsInSystem(ctx context.Context, systemPk int64) (int64, error)
	CountRoutesInSystem(ctx context.Context, systemPk int64) (int64, error)
	CountStopsInSystem(ctx context.Context, systemPk int64) (int64, error)
	CountTransfersInSystem(ctx context.Context, systemPk pgtype.Int8) (int64, error)
	DeleteAlerts(ctx context.Context, alertPks []int64) error
	DeleteFeed(ctx context.Context, pk int64) error
	DeleteServiceMap(ctx context.Context, arg DeleteServiceMapParams) error
	DeleteServiceMapConfig(ctx context.Context, pk int64) error
	DeleteStaleAgencies(ctx context.Context, arg DeleteStaleAgenciesParams) error
	DeleteStaleAlerts(ctx context.Context, arg DeleteStaleAlertsParams) error
	DeleteStaleRoutes(ctx context.Context, arg DeleteStaleRoutesParams) error
	DeleteStaleStops(ctx context.Context, arg DeleteStaleStopsParams) error
	DeleteStaleTrips(ctx context.Context, arg DeleteStaleTripsParams) ([]int64, error)
	DeleteStaleVehicles(ctx context.Context, arg DeleteStaleVehiclesParams) error
	DeleteStopHeadsignRules(ctx context.Context, feedPk int64) error
	DeleteSystem(ctx context.Context, pk int64) error
	DeleteTransfers(ctx context.Context, feedPk int64) error
	DeleteTripStopTimes(ctx context.Context, pks []int64) error
	EstimateHeadwaysForRoutes(ctx context.Context, arg EstimateHeadwaysForRoutesParams) ([]EstimateHeadwaysForRoutesRow, error)
	GetAgency(ctx context.Context, arg GetAgencyParams) (Agency, error)
	GetAlertInSystem(ctx context.Context, arg GetAlertInSystemParams) (Alert, error)
	GetDestinationsForTrips(ctx context.Context, tripPks []int64) ([]GetDestinationsForTripsRow, error)
	GetFeed(ctx context.Context, arg GetFeedParams) (Feed, error)
	GetRoute(ctx context.Context, arg GetRouteParams) (Route, error)
	GetStop(ctx context.Context, arg GetStopParams) (Stop, error)
	GetSystem(ctx context.Context, id string) (System, error)
	GetTrip(ctx context.Context, arg GetTripParams) (GetTripRow, error)
	GetVehicle(ctx context.Context, arg GetVehicleParams) (GetVehicleRow, error)
	InsertAgency(ctx context.Context, arg InsertAgencyParams) (int64, error)
	InsertAlert(ctx context.Context, arg InsertAlertParams) (int64, error)
	InsertAlertActivePeriod(ctx context.Context, arg InsertAlertActivePeriodParams) error
	InsertAlertAgency(ctx context.Context, arg InsertAlertAgencyParams) error
	InsertAlertRoute(ctx context.Context, arg InsertAlertRouteParams) error
	InsertAlertStop(ctx context.Context, arg InsertAlertStopParams) error
	InsertFeed(ctx context.Context, arg InsertFeedParams) error
	InsertRoute(ctx context.Context, arg InsertRouteParams) (int64, error)
	InsertServiceMap(ctx context.Context, arg InsertServiceMapParams) (int64, error)
	InsertServiceMapConfig(ctx context.Context, arg InsertServiceMapConfigParams) error
	InsertServiceMapStop(ctx context.Context, arg []InsertServiceMapStopParams) (int64, error)
	InsertStop(ctx context.Context, arg InsertStopParams) (int64, error)
	InsertStopHeadSignRule(ctx context.Context, arg InsertStopHeadSignRuleParams) error
	InsertSystem(ctx context.Context, arg InsertSystemParams) (int64, error)
	InsertTransfer(ctx context.Context, arg InsertTransferParams) error
	InsertTrip(ctx context.Context, arg InsertTripParams) (int64, error)
	InsertTripStopTime(ctx context.Context, arg []InsertTripStopTimeParams) (int64, error)
	InsertVehicle(ctx context.Context, arg InsertVehicleParams) error
	ListActiveAlertsForAgencies(ctx context.Context, arg ListActiveAlertsForAgenciesParams) ([]ListActiveAlertsForAgenciesRow, error)
	// ListActiveAlertsForRoutes returns preview information about active alerts for the provided routes.
	ListActiveAlertsForRoutes(ctx context.Context, arg ListActiveAlertsForRoutesParams) ([]ListActiveAlertsForRoutesRow, error)
	ListActiveAlertsForStops(ctx context.Context, arg ListActiveAlertsForStopsParams) ([]ListActiveAlertsForStopsRow, error)
	ListActivePeriodsForAlerts(ctx context.Context, pks []int64) ([]ListActivePeriodsForAlertsRow, error)
	ListAgencies(ctx context.Context, systemPk int64) ([]Agency, error)
	ListAgenciesByPk(ctx context.Context, pk []int64) ([]Agency, error)
	ListAlertPksAndHashes(ctx context.Context, arg ListAlertPksAndHashesParams) ([]ListAlertPksAndHashesRow, error)
	ListAlertsInSystem(ctx context.Context, systemPk int64) ([]Alert, error)
	ListAlertsInSystemAndByIDs(ctx context.Context, arg ListAlertsInSystemAndByIDsParams) ([]Alert, error)
	ListFeeds(ctx context.Context, systemPk int64) ([]Feed, error)
	ListRoutes(ctx context.Context, systemPk int64) ([]Route, error)
	ListRoutesByPk(ctx context.Context, routePks []int64) ([]ListRoutesByPkRow, error)
	ListRoutesInAgency(ctx context.Context, agencyPk int64) ([]ListRoutesInAgencyRow, error)
	ListServiceMapConfigsInSystem(ctx context.Context, systemPk int64) ([]ServiceMapConfig, error)
	ListServiceMapsConfigIDsForStops(ctx context.Context, stopPks []int64) ([]ListServiceMapsConfigIDsForStopsRow, error)
	// TODO: make this better?
	ListServiceMapsForRoutes(ctx context.Context, routePks []int64) ([]ListServiceMapsForRoutesRow, error)
	ListServiceMapsForStops(ctx context.Context, stopPks []int64) ([]ListServiceMapsForStopsRow, error)
	ListStopHeadsignRulesForStops(ctx context.Context, stopPks []int64) ([]StopHeadsignRule, error)
	ListStopPksForRealtimeMap(ctx context.Context, routePk int64) ([]ListStopPksForRealtimeMapRow, error)
	ListStops(ctx context.Context, arg ListStopsParams) ([]Stop, error)
	ListStopsByPk(ctx context.Context, stopPks []int64) ([]ListStopsByPkRow, error)
	ListStopsTimesForTrip(ctx context.Context, tripPk int64) ([]ListStopsTimesForTripRow, error)
	ListStops_Geographic(ctx context.Context, arg ListStops_GeographicParams) ([]Stop, error)
	ListSystems(ctx context.Context) ([]System, error)
	ListTransfersFromStops(ctx context.Context, fromStopPks []int64) ([]Transfer, error)
	ListTransfersInSystem(ctx context.Context, systemPk pgtype.Int8) ([]ListTransfersInSystemRow, error)
	ListTripPksInSystem(ctx context.Context, arg ListTripPksInSystemParams) ([]ListTripPksInSystemRow, error)
	ListTripStopTimesByStops(ctx context.Context, stopPks []int64) ([]ListTripStopTimesByStopsRow, error)
	ListTripStopTimesForUpdate(ctx context.Context, tripPks []int64) ([]ListTripStopTimesForUpdateRow, error)
	ListTrips(ctx context.Context, routePks []int64) ([]ListTripsRow, error)
	ListVehicleUniqueColumns(ctx context.Context, arg ListVehicleUniqueColumnsParams) ([]ListVehicleUniqueColumnsRow, error)
	ListVehicles(ctx context.Context, arg ListVehiclesParams) ([]ListVehiclesRow, error)
	ListVehicles_Geographic(ctx context.Context, arg ListVehicles_GeographicParams) ([]ListVehicles_GeographicRow, error)
	MapAgencyPkToId(ctx context.Context, systemPk int64) ([]MapAgencyPkToIdRow, error)
	MapRouteIDToPkInSystem(ctx context.Context, arg MapRouteIDToPkInSystemParams) ([]MapRouteIDToPkInSystemRow, error)
	MapStopIDAndPkToStationPk(ctx context.Context, arg MapStopIDAndPkToStationPkParams) ([]MapStopIDAndPkToStationPkRow, error)
	MapStopIDToPk(ctx context.Context, arg MapStopIDToPkParams) ([]MapStopIDToPkRow, error)
	MapStopPkToChildPks(ctx context.Context, stopPks []int64) ([]MapStopPkToChildPksRow, error)
	MapStopPkToDescendentPks(ctx context.Context, stopPks []int64) ([]MapStopPkToDescendentPksRow, error)
	MapTripIDToPkInSystem(ctx context.Context, arg MapTripIDToPkInSystemParams) ([]MapTripIDToPkInSystemRow, error)
	MarkFailedUpdate(ctx context.Context, arg MarkFailedUpdateParams) error
	MarkSkippedUpdate(ctx context.Context, arg MarkSkippedUpdateParams) error
	MarkSuccessfulUpdate(ctx context.Context, arg MarkSuccessfulUpdateParams) error
	MarkTripStopTimesPast(ctx context.Context, arg []MarkTripStopTimesPastParams) *MarkTripStopTimesPastBatchResults
	UpdateAgency(ctx context.Context, arg UpdateAgencyParams) error
	UpdateFeed(ctx context.Context, arg UpdateFeedParams) error
	UpdateRoute(ctx context.Context, arg UpdateRouteParams) error
	UpdateServiceMapConfig(ctx context.Context, arg UpdateServiceMapConfigParams) error
	UpdateStop(ctx context.Context, arg UpdateStopParams) error
	UpdateStop_Parent(ctx context.Context, arg UpdateStop_ParentParams) error
	UpdateSystem(ctx context.Context, arg UpdateSystemParams) error
	UpdateSystemStatus(ctx context.Context, arg UpdateSystemStatusParams) error
	UpdateTrip(ctx context.Context, arg []UpdateTripParams) *UpdateTripBatchResults
	UpdateTripStopTime(ctx context.Context, arg UpdateTripStopTimeParams) error
	UpdateVehicle(ctx context.Context, arg UpdateVehicleParams) error
}

type Queries

type Queries struct {
	// contains filtered or unexported fields
}

func New

func New(db DBTX) *Queries

func (*Queries) CountAgenciesInSystem

func (q *Queries) CountAgenciesInSystem(ctx context.Context, systemPk int64) (int64, error)

func (*Queries) CountFeedsInSystem

func (q *Queries) CountFeedsInSystem(ctx context.Context, systemPk int64) (int64, error)

func (*Queries) CountRoutesInSystem

func (q *Queries) CountRoutesInSystem(ctx context.Context, systemPk int64) (int64, error)

func (*Queries) CountStopsInSystem

func (q *Queries) CountStopsInSystem(ctx context.Context, systemPk int64) (int64, error)

func (*Queries) CountTransfersInSystem

func (q *Queries) CountTransfersInSystem(ctx context.Context, systemPk pgtype.Int8) (int64, error)

func (*Queries) DeleteAlerts

func (q *Queries) DeleteAlerts(ctx context.Context, alertPks []int64) error

func (*Queries) DeleteFeed

func (q *Queries) DeleteFeed(ctx context.Context, pk int64) error

func (*Queries) DeleteServiceMap

func (q *Queries) DeleteServiceMap(ctx context.Context, arg DeleteServiceMapParams) error

func (*Queries) DeleteServiceMapConfig

func (q *Queries) DeleteServiceMapConfig(ctx context.Context, pk int64) error

func (*Queries) DeleteStaleAgencies

func (q *Queries) DeleteStaleAgencies(ctx context.Context, arg DeleteStaleAgenciesParams) error

func (*Queries) DeleteStaleAlerts

func (q *Queries) DeleteStaleAlerts(ctx context.Context, arg DeleteStaleAlertsParams) error

func (*Queries) DeleteStaleRoutes

func (q *Queries) DeleteStaleRoutes(ctx context.Context, arg DeleteStaleRoutesParams) error

func (*Queries) DeleteStaleStops

func (q *Queries) DeleteStaleStops(ctx context.Context, arg DeleteStaleStopsParams) error

func (*Queries) DeleteStaleTrips

func (q *Queries) DeleteStaleTrips(ctx context.Context, arg DeleteStaleTripsParams) ([]int64, error)

func (*Queries) DeleteStaleVehicles

func (q *Queries) DeleteStaleVehicles(ctx context.Context, arg DeleteStaleVehiclesParams) error

func (*Queries) DeleteStopHeadsignRules

func (q *Queries) DeleteStopHeadsignRules(ctx context.Context, feedPk int64) error

func (*Queries) DeleteSystem

func (q *Queries) DeleteSystem(ctx context.Context, pk int64) error

func (*Queries) DeleteTransfers

func (q *Queries) DeleteTransfers(ctx context.Context, feedPk int64) error

func (*Queries) DeleteTripStopTimes

func (q *Queries) DeleteTripStopTimes(ctx context.Context, pks []int64) error

func (*Queries) EstimateHeadwaysForRoutes

func (q *Queries) EstimateHeadwaysForRoutes(ctx context.Context, arg EstimateHeadwaysForRoutesParams) ([]EstimateHeadwaysForRoutesRow, error)

func (*Queries) GetAgency

func (q *Queries) GetAgency(ctx context.Context, arg GetAgencyParams) (Agency, error)

func (*Queries) GetAlertInSystem

func (q *Queries) GetAlertInSystem(ctx context.Context, arg GetAlertInSystemParams) (Alert, error)

func (*Queries) GetDestinationsForTrips

func (q *Queries) GetDestinationsForTrips(ctx context.Context, tripPks []int64) ([]GetDestinationsForTripsRow, error)

func (*Queries) GetFeed

func (q *Queries) GetFeed(ctx context.Context, arg GetFeedParams) (Feed, error)

func (*Queries) GetRoute

func (q *Queries) GetRoute(ctx context.Context, arg GetRouteParams) (Route, error)

func (*Queries) GetStop

func (q *Queries) GetStop(ctx context.Context, arg GetStopParams) (Stop, error)

func (*Queries) GetSystem

func (q *Queries) GetSystem(ctx context.Context, id string) (System, error)

func (*Queries) GetTrip

func (q *Queries) GetTrip(ctx context.Context, arg GetTripParams) (GetTripRow, error)

func (*Queries) GetVehicle

func (q *Queries) GetVehicle(ctx context.Context, arg GetVehicleParams) (GetVehicleRow, error)

func (*Queries) InsertAgency

func (q *Queries) InsertAgency(ctx context.Context, arg InsertAgencyParams) (int64, error)

func (*Queries) InsertAlert

func (q *Queries) InsertAlert(ctx context.Context, arg InsertAlertParams) (int64, error)

func (*Queries) InsertAlertActivePeriod

func (q *Queries) InsertAlertActivePeriod(ctx context.Context, arg InsertAlertActivePeriodParams) error

func (*Queries) InsertAlertAgency

func (q *Queries) InsertAlertAgency(ctx context.Context, arg InsertAlertAgencyParams) error

func (*Queries) InsertAlertRoute

func (q *Queries) InsertAlertRoute(ctx context.Context, arg InsertAlertRouteParams) error

func (*Queries) InsertAlertStop

func (q *Queries) InsertAlertStop(ctx context.Context, arg InsertAlertStopParams) error

func (*Queries) InsertFeed

func (q *Queries) InsertFeed(ctx context.Context, arg InsertFeedParams) error

func (*Queries) InsertRoute

func (q *Queries) InsertRoute(ctx context.Context, arg InsertRouteParams) (int64, error)

func (*Queries) InsertServiceMap

func (q *Queries) InsertServiceMap(ctx context.Context, arg InsertServiceMapParams) (int64, error)

func (*Queries) InsertServiceMapConfig

func (q *Queries) InsertServiceMapConfig(ctx context.Context, arg InsertServiceMapConfigParams) error

func (*Queries) InsertServiceMapStop

func (q *Queries) InsertServiceMapStop(ctx context.Context, arg []InsertServiceMapStopParams) (int64, error)

func (*Queries) InsertStop

func (q *Queries) InsertStop(ctx context.Context, arg InsertStopParams) (int64, error)

func (*Queries) InsertStopHeadSignRule

func (q *Queries) InsertStopHeadSignRule(ctx context.Context, arg InsertStopHeadSignRuleParams) error

func (*Queries) InsertSystem

func (q *Queries) InsertSystem(ctx context.Context, arg InsertSystemParams) (int64, error)

func (*Queries) InsertTransfer

func (q *Queries) InsertTransfer(ctx context.Context, arg InsertTransferParams) error

func (*Queries) InsertTrip

func (q *Queries) InsertTrip(ctx context.Context, arg InsertTripParams) (int64, error)

func (*Queries) InsertTripStopTime

func (q *Queries) InsertTripStopTime(ctx context.Context, arg []InsertTripStopTimeParams) (int64, error)

func (*Queries) InsertVehicle

func (q *Queries) InsertVehicle(ctx context.Context, arg InsertVehicleParams) error

func (*Queries) ListActiveAlertsForRoutes

func (q *Queries) ListActiveAlertsForRoutes(ctx context.Context, arg ListActiveAlertsForRoutesParams) ([]ListActiveAlertsForRoutesRow, error)

ListActiveAlertsForRoutes returns preview information about active alerts for the provided routes.

func (*Queries) ListActiveAlertsForStops

func (q *Queries) ListActiveAlertsForStops(ctx context.Context, arg ListActiveAlertsForStopsParams) ([]ListActiveAlertsForStopsRow, error)

func (*Queries) ListActivePeriodsForAlerts

func (q *Queries) ListActivePeriodsForAlerts(ctx context.Context, pks []int64) ([]ListActivePeriodsForAlertsRow, error)

func (*Queries) ListAgencies

func (q *Queries) ListAgencies(ctx context.Context, systemPk int64) ([]Agency, error)

func (*Queries) ListAgenciesByPk

func (q *Queries) ListAgenciesByPk(ctx context.Context, pk []int64) ([]Agency, error)

func (*Queries) ListAlertPksAndHashes

func (q *Queries) ListAlertPksAndHashes(ctx context.Context, arg ListAlertPksAndHashesParams) ([]ListAlertPksAndHashesRow, error)

func (*Queries) ListAlertsInSystem

func (q *Queries) ListAlertsInSystem(ctx context.Context, systemPk int64) ([]Alert, error)

func (*Queries) ListAlertsInSystemAndByIDs

func (q *Queries) ListAlertsInSystemAndByIDs(ctx context.Context, arg ListAlertsInSystemAndByIDsParams) ([]Alert, error)

func (*Queries) ListFeeds

func (q *Queries) ListFeeds(ctx context.Context, systemPk int64) ([]Feed, error)

func (*Queries) ListRoutes

func (q *Queries) ListRoutes(ctx context.Context, systemPk int64) ([]Route, error)

func (*Queries) ListRoutesByPk

func (q *Queries) ListRoutesByPk(ctx context.Context, routePks []int64) ([]ListRoutesByPkRow, error)

func (*Queries) ListRoutesInAgency

func (q *Queries) ListRoutesInAgency(ctx context.Context, agencyPk int64) ([]ListRoutesInAgencyRow, error)

func (*Queries) ListServiceMapConfigsInSystem

func (q *Queries) ListServiceMapConfigsInSystem(ctx context.Context, systemPk int64) ([]ServiceMapConfig, error)

func (*Queries) ListServiceMapsConfigIDsForStops

func (q *Queries) ListServiceMapsConfigIDsForStops(ctx context.Context, stopPks []int64) ([]ListServiceMapsConfigIDsForStopsRow, error)

func (*Queries) ListServiceMapsForRoutes

func (q *Queries) ListServiceMapsForRoutes(ctx context.Context, routePks []int64) ([]ListServiceMapsForRoutesRow, error)

TODO: make this better?

func (*Queries) ListServiceMapsForStops

func (q *Queries) ListServiceMapsForStops(ctx context.Context, stopPks []int64) ([]ListServiceMapsForStopsRow, error)

func (*Queries) ListStopHeadsignRulesForStops

func (q *Queries) ListStopHeadsignRulesForStops(ctx context.Context, stopPks []int64) ([]StopHeadsignRule, error)

func (*Queries) ListStopPksForRealtimeMap

func (q *Queries) ListStopPksForRealtimeMap(ctx context.Context, routePk int64) ([]ListStopPksForRealtimeMapRow, error)

func (*Queries) ListStops

func (q *Queries) ListStops(ctx context.Context, arg ListStopsParams) ([]Stop, error)

func (*Queries) ListStopsByPk

func (q *Queries) ListStopsByPk(ctx context.Context, stopPks []int64) ([]ListStopsByPkRow, error)

func (*Queries) ListStopsTimesForTrip

func (q *Queries) ListStopsTimesForTrip(ctx context.Context, tripPk int64) ([]ListStopsTimesForTripRow, error)

func (*Queries) ListStops_Geographic

func (q *Queries) ListStops_Geographic(ctx context.Context, arg ListStops_GeographicParams) ([]Stop, error)

func (*Queries) ListSystems

func (q *Queries) ListSystems(ctx context.Context) ([]System, error)

func (*Queries) ListTransfersFromStops

func (q *Queries) ListTransfersFromStops(ctx context.Context, fromStopPks []int64) ([]Transfer, error)

func (*Queries) ListTransfersInSystem

func (q *Queries) ListTransfersInSystem(ctx context.Context, systemPk pgtype.Int8) ([]ListTransfersInSystemRow, error)

func (*Queries) ListTripPksInSystem

func (q *Queries) ListTripPksInSystem(ctx context.Context, arg ListTripPksInSystemParams) ([]ListTripPksInSystemRow, error)

func (*Queries) ListTripStopTimesByStops

func (q *Queries) ListTripStopTimesByStops(ctx context.Context, stopPks []int64) ([]ListTripStopTimesByStopsRow, error)

func (*Queries) ListTripStopTimesForUpdate

func (q *Queries) ListTripStopTimesForUpdate(ctx context.Context, tripPks []int64) ([]ListTripStopTimesForUpdateRow, error)

func (*Queries) ListTrips

func (q *Queries) ListTrips(ctx context.Context, routePks []int64) ([]ListTripsRow, error)

func (*Queries) ListVehicleUniqueColumns

func (q *Queries) ListVehicleUniqueColumns(ctx context.Context, arg ListVehicleUniqueColumnsParams) ([]ListVehicleUniqueColumnsRow, error)

func (*Queries) ListVehicles

func (q *Queries) ListVehicles(ctx context.Context, arg ListVehiclesParams) ([]ListVehiclesRow, error)

func (*Queries) ListVehicles_Geographic

func (q *Queries) ListVehicles_Geographic(ctx context.Context, arg ListVehicles_GeographicParams) ([]ListVehicles_GeographicRow, error)

func (*Queries) MapAgencyPkToId

func (q *Queries) MapAgencyPkToId(ctx context.Context, systemPk int64) ([]MapAgencyPkToIdRow, error)

func (*Queries) MapRouteIDToPkInSystem

func (q *Queries) MapRouteIDToPkInSystem(ctx context.Context, arg MapRouteIDToPkInSystemParams) ([]MapRouteIDToPkInSystemRow, error)

func (*Queries) MapStopIDAndPkToStationPk

func (q *Queries) MapStopIDAndPkToStationPk(ctx context.Context, arg MapStopIDAndPkToStationPkParams) ([]MapStopIDAndPkToStationPkRow, error)

func (*Queries) MapStopIDToPk

func (q *Queries) MapStopIDToPk(ctx context.Context, arg MapStopIDToPkParams) ([]MapStopIDToPkRow, error)

func (*Queries) MapStopPkToChildPks

func (q *Queries) MapStopPkToChildPks(ctx context.Context, stopPks []int64) ([]MapStopPkToChildPksRow, error)

func (*Queries) MapStopPkToDescendentPks

func (q *Queries) MapStopPkToDescendentPks(ctx context.Context, stopPks []int64) ([]MapStopPkToDescendentPksRow, error)

func (*Queries) MapTripIDToPkInSystem

func (q *Queries) MapTripIDToPkInSystem(ctx context.Context, arg MapTripIDToPkInSystemParams) ([]MapTripIDToPkInSystemRow, error)

func (*Queries) MarkFailedUpdate

func (q *Queries) MarkFailedUpdate(ctx context.Context, arg MarkFailedUpdateParams) error

func (*Queries) MarkSkippedUpdate

func (q *Queries) MarkSkippedUpdate(ctx context.Context, arg MarkSkippedUpdateParams) error

func (*Queries) MarkSuccessfulUpdate

func (q *Queries) MarkSuccessfulUpdate(ctx context.Context, arg MarkSuccessfulUpdateParams) error

func (*Queries) UpdateAgency

func (q *Queries) UpdateAgency(ctx context.Context, arg UpdateAgencyParams) error

func (*Queries) UpdateFeed

func (q *Queries) UpdateFeed(ctx context.Context, arg UpdateFeedParams) error

func (*Queries) UpdateRoute

func (q *Queries) UpdateRoute(ctx context.Context, arg UpdateRouteParams) error

func (*Queries) UpdateServiceMapConfig

func (q *Queries) UpdateServiceMapConfig(ctx context.Context, arg UpdateServiceMapConfigParams) error

func (*Queries) UpdateStop

func (q *Queries) UpdateStop(ctx context.Context, arg UpdateStopParams) error

func (*Queries) UpdateStop_Parent

func (q *Queries) UpdateStop_Parent(ctx context.Context, arg UpdateStop_ParentParams) error

func (*Queries) UpdateSystem

func (q *Queries) UpdateSystem(ctx context.Context, arg UpdateSystemParams) error

func (*Queries) UpdateSystemStatus

func (q *Queries) UpdateSystemStatus(ctx context.Context, arg UpdateSystemStatusParams) error

func (*Queries) UpdateTrip

func (q *Queries) UpdateTrip(ctx context.Context, arg []UpdateTripParams) *UpdateTripBatchResults

func (*Queries) UpdateTripStopTime

func (q *Queries) UpdateTripStopTime(ctx context.Context, arg UpdateTripStopTimeParams) error

func (*Queries) UpdateVehicle

func (q *Queries) UpdateVehicle(ctx context.Context, arg UpdateVehicleParams) error

func (*Queries) WithTx

func (q *Queries) WithTx(tx pgx.Tx) *Queries

type Route

type Route struct {
	Pk                int64
	ID                string
	SystemPk          int64
	Color             string
	TextColor         string
	ShortName         pgtype.Text
	LongName          pgtype.Text
	Description       pgtype.Text
	Url               pgtype.Text
	SortOrder         pgtype.Int4
	Type              string
	AgencyPk          int64
	ContinuousDropOff string
	ContinuousPickup  string
	FeedPk            int64
}

type ScheduledService

type ScheduledService struct {
	Pk        int64
	ID        string
	SystemPk  int64
	Monday    pgtype.Bool
	Tuesday   pgtype.Bool
	Wednesday pgtype.Bool
	Thursday  pgtype.Bool
	Friday    pgtype.Bool
	Saturday  pgtype.Bool
	Sunday    pgtype.Bool
	EndDate   pgtype.Date
	StartDate pgtype.Date
	FeedPk    int64
}

type ScheduledServiceAddition

type ScheduledServiceAddition struct {
	Pk        int64
	ServicePk int64
	Date      pgtype.Date
}

type ScheduledServiceRemoval

type ScheduledServiceRemoval struct {
	Pk        int64
	ServicePk int64
	Date      pgtype.Date
}

type ScheduledTrip

type ScheduledTrip struct {
	Pk                   int64
	ID                   string
	RoutePk              int64
	ServicePk            int64
	DirectionID          pgtype.Bool
	BikesAllowed         string
	BlockID              pgtype.Text
	Headsign             pgtype.Text
	ShortName            pgtype.Text
	WheelchairAccessible string
}

type ScheduledTripFrequency

type ScheduledTripFrequency struct {
	Pk             int64
	TripPk         int64
	StartTime      time.Time
	EndTime        time.Time
	Headway        int32
	FrequencyBased bool
}

type ScheduledTripStopTime

type ScheduledTripStopTime struct {
	Pk                    int64
	TripPk                int64
	StopPk                int64
	ArrivalTime           pgtype.Time
	DepartureTime         pgtype.Time
	StopSequence          int32
	ContinuousDropOff     string
	ContinuousPickup      string
	DropOffType           string
	ExactTimes            bool
	Headsign              pgtype.Text
	PickupType            string
	ShapeDistanceTraveled pgtype.Float8
}

type ServiceMap

type ServiceMap struct {
	Pk       int64
	RoutePk  int64
	ConfigPk int64
}

type ServiceMapConfig

type ServiceMapConfig struct {
	Pk       int64
	ID       string
	SystemPk int64
	Config   []byte
}

type ServiceMapVertex

type ServiceMapVertex struct {
	Pk       int64
	StopPk   int64
	MapPk    int64
	Position int32
}

type Stop

type Stop struct {
	Pk                 int64
	ID                 string
	SystemPk           int64
	ParentStopPk       pgtype.Int8
	Name               pgtype.Text
	Longitude          pgtype.Numeric
	Latitude           pgtype.Numeric
	Url                pgtype.Text
	Code               pgtype.Text
	Description        pgtype.Text
	PlatformCode       pgtype.Text
	Timezone           pgtype.Text
	Type               string
	WheelchairBoarding pgtype.Bool
	ZoneID             pgtype.Text
	FeedPk             int64
}

type StopHeadsignRule

type StopHeadsignRule struct {
	Pk       int64
	Priority int32
	StopPk   int64
	Track    pgtype.Text
	Headsign string
	FeedPk   int64
}

type System

type System struct {
	Pk       int64
	ID       string
	Name     string
	Timezone pgtype.Text
	Status   string
}

type Transfer

type Transfer struct {
	Pk              int64
	SystemPk        pgtype.Int8
	FromStopPk      int64
	ToStopPk        int64
	Type            string
	MinTransferTime pgtype.Int4
	Distance        pgtype.Int4
	FeedPk          int64
}

type Trip

type Trip struct {
	Pk          int64
	ID          string
	RoutePk     int64
	DirectionID pgtype.Bool
	StartedAt   pgtype.Timestamptz
	GtfsHash    string
	FeedPk      int64
}

type TripStopTime

type TripStopTime struct {
	Pk                   int64
	StopPk               int64
	TripPk               int64
	ArrivalTime          pgtype.Timestamptz
	ArrivalDelay         pgtype.Int4
	ArrivalUncertainty   pgtype.Int4
	DepartureTime        pgtype.Timestamptz
	DepartureDelay       pgtype.Int4
	DepartureUncertainty pgtype.Int4
	StopSequence         int32
	Track                pgtype.Text
	Headsign             pgtype.Text
	Past                 bool
}

type UpdateAgencyParams

type UpdateAgencyParams struct {
	FeedPk   int64
	Name     string
	Url      string
	Timezone string
	Language pgtype.Text
	Phone    pgtype.Text
	FareUrl  pgtype.Text
	Email    pgtype.Text
	Pk       int64
}

type UpdateFeedParams

type UpdateFeedParams struct {
	Config string
	FeedPk int64
}

type UpdateRouteParams

type UpdateRouteParams struct {
	FeedPk            int64
	Color             string
	TextColor         string
	ShortName         pgtype.Text
	LongName          pgtype.Text
	Description       pgtype.Text
	Url               pgtype.Text
	SortOrder         pgtype.Int4
	Type              string
	ContinuousPickup  string
	ContinuousDropOff string
	AgencyPk          int64
	Pk                int64
}

type UpdateServiceMapConfigParams

type UpdateServiceMapConfigParams struct {
	Config []byte
	Pk     int64
}

type UpdateStopParams

type UpdateStopParams struct {
	FeedPk             int64
	Name               pgtype.Text
	Longitude          pgtype.Numeric
	Latitude           pgtype.Numeric
	Url                pgtype.Text
	Code               pgtype.Text
	Description        pgtype.Text
	PlatformCode       pgtype.Text
	Timezone           pgtype.Text
	Type               string
	WheelchairBoarding pgtype.Bool
	ZoneID             pgtype.Text
	Pk                 int64
}

type UpdateStop_ParentParams

type UpdateStop_ParentParams struct {
	ParentStopPk pgtype.Int8
	Pk           int64
}

type UpdateSystemParams

type UpdateSystemParams struct {
	Name string
	Pk   int64
}

type UpdateSystemStatusParams

type UpdateSystemStatusParams struct {
	Status string
	Pk     int64
}

type UpdateTripBatchResults

type UpdateTripBatchResults struct {
	// contains filtered or unexported fields
}

func (*UpdateTripBatchResults) Close

func (b *UpdateTripBatchResults) Close() error

func (*UpdateTripBatchResults) Exec

func (b *UpdateTripBatchResults) Exec(f func(int, error))

type UpdateTripParams

type UpdateTripParams struct {
	FeedPk      int64
	DirectionID pgtype.Bool
	StartedAt   pgtype.Timestamptz
	GtfsHash    string
	Pk          int64
}

type UpdateTripStopTimeParams

type UpdateTripStopTimeParams struct {
	StopPk               int64
	ArrivalTime          pgtype.Timestamptz
	ArrivalDelay         pgtype.Int4
	ArrivalUncertainty   pgtype.Int4
	DepartureTime        pgtype.Timestamptz
	DepartureDelay       pgtype.Int4
	DepartureUncertainty pgtype.Int4
	StopSequence         int32
	Track                pgtype.Text
	Headsign             pgtype.Text
	Pk                   int64
}

type UpdateVehicleParams

type UpdateVehicleParams struct {
	TripPk              pgtype.Int8
	Label               pgtype.Text
	LicensePlate        pgtype.Text
	CurrentStatus       pgtype.Text
	Latitude            pgtype.Numeric
	Longitude           pgtype.Numeric
	Bearing             pgtype.Float4
	Odometer            pgtype.Float8
	Speed               pgtype.Float4
	CongestionLevel     string
	UpdatedAt           pgtype.Timestamptz
	CurrentStopPk       pgtype.Int8
	CurrentStopSequence pgtype.Int4
	OccupancyStatus     pgtype.Text
	FeedPk              int64
	OccupancyPercentage pgtype.Int4
	Pk                  int64
}

type Vehicle

type Vehicle struct {
	Pk                  int64
	ID                  pgtype.Text
	SystemPk            int64
	TripPk              pgtype.Int8
	Label               pgtype.Text
	LicensePlate        pgtype.Text
	CurrentStatus       pgtype.Text
	Latitude            pgtype.Numeric
	Longitude           pgtype.Numeric
	Bearing             pgtype.Float4
	Odometer            pgtype.Float8
	Speed               pgtype.Float4
	CongestionLevel     string
	UpdatedAt           pgtype.Timestamptz
	CurrentStopPk       pgtype.Int8
	CurrentStopSequence pgtype.Int4
	OccupancyStatus     pgtype.Text
	FeedPk              int64
	OccupancyPercentage pgtype.Int4
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL