Added helpers GetPriceForStep() and GetStepForPrice() to make source

more readable.
This commit is contained in:
Gerhard Hoffmann 2023-12-12 10:40:20 +01:00
parent 63f508fb95
commit 723b3530cc

View File

@ -80,7 +80,13 @@ private:
//
uint32_t GetPriceForTimeStep(Configuration *cfg, int timeStep) const;
uint32_t GetPriceForStep(Configuration *cfg, int step) const {
return GetPriceForTimeStep(cfg, step);
}
uint32_t GetDurationForPrice(Configuration *cfg, int price) const;
uint32_t GetStepForPrice(Configuration *cfg, int price) const {
return GetDurationForPrice(cfg, price);
}
int findWorkTimeRange(QDateTime const &dt,
QScopedArrayPointer<TariffTimeRange> const &worktime,