Remove parameter paymentMethod.
Add GetDurationForPrice().
This commit is contained in:
parent
3a2e521345
commit
b80cd5e6ef
@ -32,18 +32,20 @@ public:
|
|||||||
// Daily ticket
|
// Daily ticket
|
||||||
QDateTime GetDailyTicketDuration(Configuration* cfg, const QDateTime start_datetime, uint8_t payment_option, bool carry_over);
|
QDateTime GetDailyTicketDuration(Configuration* cfg, const QDateTime start_datetime, uint8_t payment_option, bool carry_over);
|
||||||
|
|
||||||
|
//
|
||||||
|
// helper function to find time steps for a tariff with PaymentMethod::Steps
|
||||||
|
// (e.g. Schoenau/Koenigsee)
|
||||||
|
//
|
||||||
|
QList<int> GetTimeSteps(Configuration *cfg) const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
// Introduced for PaymentMethod::Steps (e.g. Schoenau)
|
// Introduced for PaymentMethod::Steps (e.g. Schoenau)
|
||||||
// For tariff of following structure: only steps, no special days, nonstop.
|
// For tariff of following structure: only steps, no special days, nonstop.
|
||||||
uint32_t GetCostFromDuration(Configuration const* cfg, QDateTime const &start, quint64 durationMinutes, uint8_t paymentMethod = PaymentMethod::Steps);
|
uint32_t GetCostFromDuration(Configuration *cfg, QDateTime const &start, quint64 durationMinutes) const;
|
||||||
uint32_t GetCostFromDuration(Configuration const* cfg, QDateTime const &start, QDateTime const &end, uint8_t paymentMethod = PaymentMethod::Steps);
|
uint32_t GetCostFromDuration(Configuration *cfg, QDateTime const &start, QDateTime const &end) const;
|
||||||
|
|
||||||
|
|
||||||
//
|
//
|
||||||
// helper functions for PaymentMethod::Steps
|
uint32_t GetPriceForTimeStep(Configuration *cfg, int timeStep) const;
|
||||||
//
|
uint32_t GetDurationForPrice(Configuration *cfg, int price) const;
|
||||||
QList<int> GetTimeSteps(Configuration const *cfg, int paymentMethod);
|
|
||||||
//
|
|
||||||
uint32_t GetPriceForTimeStep(Configuration const *cfg, uint8_t paymentMethod, int timeStep);
|
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user