repositories

package
v0.21.0 Latest Latest
Warning

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

Go to latest
Published: Oct 3, 2025 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Car

type Car interface {
	Get(context.Context) (entities.CarList, error)
	GetByID(context.Context, uuid.UUID) (*entities.Car, error)
}

type PitParameters

type PitParameters interface {
	// GetServiceDurations returns the service duration matrix for a specified
	// race class in a map by pit service name.
	GetServiceDurations(context.Context, entities.RaceClass) (entities.PitServiceDurations, error)

	// GetPitTimeLoss returns the time loss for a race class on a specified track
	// and layout, that the car will lose decelerating, driving down the pit road
	// and accelerating again, as opposed to simply driving on the race track past
	// the pits.
	GetPitTimeLoss(context.Context, entities.RaceClass, uuid.UUID, *uuid.UUID) (*entities.PitTimeLoss, error)

	// GetAveragePitTimeLoss returns the average time loss for all race calssess
	// in all track and layout combinations.
	GetAveragePitTimeLoss(context.Context) (float64, error)

	// GetAllServiceDurations returns the service duration matrix for all race
	// classes in a nested map by race class and pit service name.
	GetAllServiceDurations(context.Context) (map[entities.RaceClass]entities.PitServiceDurations, error)
}

type Track

type Track interface {
	Get(context.Context) (entities.TrackList, error)
	GetByID(context.Context, uuid.UUID) (*entities.Track, error)
}

type TrackLayout

type TrackLayout interface {
	Get(context.Context) (entities.TrackLayoutList, error)
	GetByID(context.Context, uuid.UUID) (*entities.TrackLayout, error)
	GetTrackDefault(context.Context, uuid.UUID) (*uuid.UUID, error)
}

type User

type User interface {
	GetByID(context.Context, uuid.UUID) (*entities.User, error)
}

Jump to

Keyboard shortcuts

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