Documentation ¶
Index ¶
- func CollectMessages(ctx context.Context, conn repository.Querier, eventId int) ([]*racestatev1.MessageContainer, error)
- func CreateDummyRaceStateInfo(ctx context.Context, conn repository.Querier, eventId int, ts time.Time) (rsInfoId int, err error)
- func CreateRaceState(ctx context.Context, conn repository.Querier, eventId int, ...) (rsInfoId int, err error)
- func DeleteByEventId(ctx context.Context, conn repository.Querier, eventId int) (int, error)
- func FindNearestRaceState(ctx context.Context, conn repository.Querier, eventId int, sessionTime float32) (rsInfoId int, err error)
- func LoadLatest(ctx context.Context, conn repository.Querier, eventId int) (*racestatev1.PublishStateRequest, error)
- func LoadRange(ctx context.Context, conn repository.Querier, eventId int, startTS time.Time, ...) ([]*racestatev1.PublishStateRequest, time.Time, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CollectMessages ¶
func CollectMessages( ctx context.Context, conn repository.Querier, eventId int, ) ([]*racestatev1.MessageContainer, error)
func CreateDummyRaceStateInfo ¶ added in v0.14.2
func CreateDummyRaceStateInfo( ctx context.Context, conn repository.Querier, eventId int, ts time.Time, ) (rsInfoId int, err error)
this method is used if there are driver data prior to the first race state this should not happen but may occur on migration from old wamp data
func CreateRaceState ¶
func CreateRaceState( ctx context.Context, conn repository.Querier, eventId int, racestate *racestatev1.PublishStateRequest, ) (rsInfoId int, err error)
stores the racestate info and the protobuf message in the database returns the id of the created rs_info entry for further use
func DeleteByEventId ¶
deletes all entries for an event from the database, returns number of rows deleted.
func FindNearestRaceState ¶
func LoadLatest ¶
func LoadLatest( ctx context.Context, conn repository.Querier, eventId int, ) (*racestatev1.PublishStateRequest, error)
func LoadRange ¶
func LoadRange( ctx context.Context, conn repository.Querier, eventId int, startTS time.Time, limit int, ) ([]*racestatev1.PublishStateRequest, time.Time, error)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.