Documentation ¶
Index ¶
- func GetAftermarketDeviceByID(ctx context.Context, id int) (*model.AftermarketDevice, error)
- func GetAftermarketDeviceByVehicleID(ctx context.Context, vehicleID int) (*model.AftermarketDevice, error)
- func GetDCNByVehicleID(ctx context.Context, vehicleID int) (*gmodel.Dcn, error)
- func GetManufacturerID(ctx context.Context, manufacturerID int) (*model.Manufacturer, error)
- func GetSyntheticDeviceByID(ctx context.Context, vehicleID int) (*gmodel.SyntheticDevice, error)
- func GetSyntheticDeviceByVehicleID(ctx context.Context, vehicleID int) (*gmodel.SyntheticDevice, error)
- func GetVehicleByID(ctx context.Context, vehicleID int) (*model.Vehicle, error)
- func Middleware(db db.Store, next http.Handler, settings config.Settings) http.Handler
- type AftermarketDeviceLoader
- func (ad *AftermarketDeviceLoader) BatchGetAftermarketDeviceByID(ctx context.Context, aftermarketDeviceIDs []int) []*dataloader.Result[*model.AftermarketDevice]
- func (ad *AftermarketDeviceLoader) BatchGetLinkedAftermarketDeviceByVehicleID(ctx context.Context, vehicleIDs []int) []*dataloader.Result[*model.AftermarketDevice]
- type DCNLoader
- type Loaders
- type ManufacturerLoader
- type SyntheticDeviceLoader
- func (sd *SyntheticDeviceLoader) BatchGetSyntheticDeviceByID(ctx context.Context, syntheticDeviceIDs []int) []*dataloader.Result[*gmodel.SyntheticDevice]
- func (sd *SyntheticDeviceLoader) BatchGetSyntheticDeviceByVehicleID(ctx context.Context, vehicleIDs []int) []*dataloader.Result[*gmodel.SyntheticDevice]
- type VehicleLoader
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetAftermarketDeviceByID ¶ added in v0.1.7
func GetDCNByVehicleID ¶
func GetManufacturerID ¶
func GetSyntheticDeviceByID ¶ added in v0.1.7
func GetVehicleByID ¶
Types ¶
type AftermarketDeviceLoader ¶
type AftermarketDeviceLoader struct {
// contains filtered or unexported fields
}
func (*AftermarketDeviceLoader) BatchGetAftermarketDeviceByID ¶ added in v0.1.7
func (ad *AftermarketDeviceLoader) BatchGetAftermarketDeviceByID(ctx context.Context, aftermarketDeviceIDs []int) []*dataloader.Result[*model.AftermarketDevice]
BatchGetAftermarketDeviceByID implements the dataloader for finding aftermarket devices by their ids and returns them in the order requested
func (*AftermarketDeviceLoader) BatchGetLinkedAftermarketDeviceByVehicleID ¶
func (ad *AftermarketDeviceLoader) BatchGetLinkedAftermarketDeviceByVehicleID(ctx context.Context, vehicleIDs []int) []*dataloader.Result[*model.AftermarketDevice]
BatchGetLinkedAftermarketDeviceByVehicleID implements the dataloader for finding aftermarket devices linked to vehicles and returns them in the order requested
type Loaders ¶
type Loaders struct { VehicleByID dataloader.Interface[int, *model.Vehicle] AftermarketDeviceByVehicleID dataloader.Interface[int, *model.AftermarketDevice] SyntheticDeviceByVehicleID dataloader.Interface[int, *model.SyntheticDevice] DCNByVehicleID dataloader.Interface[int, *model.Dcn] ManufacturerByID dataloader.Interface[int, *model.Manufacturer] AftermarketDeviceByID dataloader.Interface[int, *model.AftermarketDevice] SyntheticDeviceByID dataloader.Interface[int, *model.SyntheticDevice] }
type ManufacturerLoader ¶
type ManufacturerLoader struct {
// contains filtered or unexported fields
}
func (*ManufacturerLoader) BatchGetManufacturerByID ¶
func (v *ManufacturerLoader) BatchGetManufacturerByID(ctx context.Context, manufacturerIDs []int) []*dataloader.Result[*model.Manufacturer]
type SyntheticDeviceLoader ¶
type SyntheticDeviceLoader struct {
// contains filtered or unexported fields
}
func (*SyntheticDeviceLoader) BatchGetSyntheticDeviceByID ¶ added in v0.1.7
func (sd *SyntheticDeviceLoader) BatchGetSyntheticDeviceByID(ctx context.Context, syntheticDeviceIDs []int) []*dataloader.Result[*gmodel.SyntheticDevice]
BatchGetSyntheticDeviceByVehicleID implements the dataloader for finding synthetic devices by their ids and returns them in the order requested
func (*SyntheticDeviceLoader) BatchGetSyntheticDeviceByVehicleID ¶
func (sd *SyntheticDeviceLoader) BatchGetSyntheticDeviceByVehicleID(ctx context.Context, vehicleIDs []int) []*dataloader.Result[*gmodel.SyntheticDevice]
BatchGetSyntheticDeviceByVehicleID implements the dataloader for finding synthetic devices linked to vehicles and returns them in the order requested
type VehicleLoader ¶
type VehicleLoader struct {
// contains filtered or unexported fields
}
func (*VehicleLoader) BatchGetVehicleByID ¶ added in v0.1.7
func (v *VehicleLoader) BatchGetVehicleByID(ctx context.Context, vehicleIDs []int) []*dataloader.Result[*model.Vehicle]
BatchGetVehicleByID implements the dataloader for finding vehicles by their ids.