Add description for tariff-settings.w

This commit is contained in:
Gerhard Hoffmann 2024-09-02 16:46:00 +02:00
parent 3a18ee2d7c
commit 53cf9a7341

View File

@ -0,0 +1,40 @@
#ifndef ATB_TARIFF_SETTINGS_H_INCLUDED
#define ATB_TARIFF_SETTINGS_H_INCLUDED
#include <QDebug>
struct ATBTariffSettings {
int m_max_price;
int m_min_price;
int m_max_time;
int m_min_time;
explicit ATBTariffSettings()
: m_max_price(0)
, m_min_price(0)
, m_max_time(0)
, m_min_time(0) {
}
explicit ATBTariffSettings(int max_price, int min_price, int max_time, int min_time)
: m_max_price(max_price)
, m_min_price(min_price)
, m_max_time(max_time)
, m_min_time(min_time) {
}
friend QDebug operator<<(QDebug debug, ATBTariffSettings const &ts) {
QDebugStateSaver saver(debug);
debug.nospace()
<< " max_price: " << ts.m_max_price << "\n"
<< " min_price: " << ts.m_min_price << "\n"
<< " max_time: " << ts.m_max_time << "\n"
<< " min_time: " << ts.m_min_time << endl;
return debug;
}
};
#endif // ATB_TARIFF_SETTINGS_H_INCLUDED