MileageAlgorithmRegistry

Where algorithms are looked up by id.

Deliberately a plain map rather than a service-loader or DI-aware thing: it must work identically in a unit test, in a sweep harness on the desktop, and in the app.

Constructors

Link copied to clipboard
constructor(factories: Map<AlgorithmId, (TuningProfile, DeviceEnvelope) -> MileageAlgorithm> = emptyMap())

Properties

Link copied to clipboard

Functions

Link copied to clipboard
fun create(profile: TuningProfile, envelope: DeviceEnvelope = DeviceEnvelope.Default): MileageAlgorithm