Documentation ¶
Overview ¶
Package dbwrappers contains methods that wrap the raw methods generated by sqlc and provide a nicer API.
Index ¶
- func BatchUpdate[T any, S batchResult](ctx context.Context, f func(ctx context.Context, args []T) S, args []T) error
- func ListStopTimesForUpdate(ctx context.Context, querier db.Querier, tripUIDToPk map[TripUID]int64) (map[TripUID][]db.ListTripStopTimesForUpdateRow, error)
- func ListTripsForUpdate(ctx context.Context, querier db.Querier, systemPk int64, routePks []int64) (map[TripUID]db.ListTripsRow, error)
- func MapAgencyIDToPk(ctx context.Context, querier db.Querier, systemPk int64) (map[string]int64, error)
- func MapRouteIDToPkInSystem(ctx context.Context, querier db.Querier, systemPk int64, routeIDs ...[]string) (map[string]int64, error)
- func MapScheduledTripIDToPkInSystem(ctx context.Context, queries db.Querier, systemPk int64, ...) (map[string]int64, error)
- func MapScheduledTripIDToRoutePkInSystem(ctx context.Context, queries db.Querier, systemPk int64, ...) (map[string]int64, error)
- func MapStopIDToPkInSystem(ctx context.Context, querier db.Querier, systemPk int64, stopIDs ...[]string) (map[string]int64, error)
- func MapStopIDToStationPk(ctx context.Context, querier db.Querier, systemPk int64) (map[string]int64, error)
- func MapStopPkToChildPks(ctx context.Context, querier db.Querier, stopPks []int64) (map[int64][]int64, error)
- func MapStopPkToDescendentPks(ctx context.Context, querier db.Querier, stopPks []int64) (map[int64]map[int64]bool, error)
- func MapStopPkToStationPk(ctx context.Context, querier db.Querier, systemPk int64, stopPks []int64) (map[int64]int64, error)
- func MapTripIDToPkInSystem(ctx context.Context, querier db.Querier, systemPk int64, tripIDs ...[]string) (map[string]int64, error)
- func MapTripPkToVehicleID(ctx context.Context, querier db.Querier, systemPk int64, vehicleIDs []string) (map[int64]string, error)
- func Ping(ctx context.Context, logger *slog.Logger, pool *pgxpool.Pool, numRetries int, ...) error
- type TripUID
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BatchUpdate ¶
func ListStopTimesForUpdate ¶
func ListTripsForUpdate ¶
func MapAgencyIDToPk ¶
func MapRouteIDToPkInSystem ¶
func MapScheduledTripIDToPkInSystem ¶ added in v0.6.1
func MapScheduledTripIDToRoutePkInSystem ¶ added in v0.6.1
func MapStopIDToPkInSystem ¶
func MapStopIDToStationPk ¶
func MapStopPkToChildPks ¶
func MapStopPkToStationPk ¶
func MapTripIDToPkInSystem ¶
func MapTripPkToVehicleID ¶ added in v0.6.1
Types ¶
Click to show internal directories.
Click to hide internal directories.