Hotwheels-Cluster 1.2
Creation of Cluster APP for SEA:ME project.
 
Loading...
Searching...
No Matches
SystemManager.hpp
Go to the documentation of this file.
1
15
16#ifndef SYSTEMMANAGER_HPP
17#define SYSTEMMANAGER_HPP
18
19#include <QObject>
20#include <QTimer>
21
25
30class SystemManager : public QObject {
31 Q_OBJECT
32
33public:
34 explicit SystemManager(IBatteryController *batteryController = nullptr,
35 ISystemInfoProvider *systemInfoProvider = nullptr,
36 ISystemCommandExecutor *systemCommandExecutor = nullptr,
37 QObject *parent = nullptr);
39
40 void initialize();
41 void shutdown();
42
43 QTimer &getTimeTimer() { return this->m_timeTimer; };
44 QTimer &getStatusTimer() { return this->m_statusTimer; };
45
46signals:
47 void timeUpdated(const QString &currentDate,
48 const QString &currentTime,
49 const QString &currentDay);
50 void wifiStatusUpdated(const QString &status, const QString &wifiName);
51 void temperatureUpdated(const QString &temperature);
52 void batteryPercentageUpdated(float batteryPercentage);
53 void ipAddressUpdated(const QString &ipAddress);
54
55public slots:
56 void updateTime();
57 void updateSystemStatus();
58
59private:
68};
69
70#endif // SYSTEMMANAGER_HPP
Definition of the IBatteryController interface.
Definition of the ISystemCommandExecutor interface.
Definition of the ISystemInfoProvider interface.
Interface for managing the battery of the vehicle.
Interface for executing system commands and reading files.
Interface for providing system information to the display manager.
void ipAddressUpdated(const QString &ipAddress)
~SystemManager()
Destructor for the SystemManager class.
QTimer & getTimeTimer()
void batteryPercentageUpdated(float batteryPercentage)
void wifiStatusUpdated(const QString &status, const QString &wifiName)
ISystemCommandExecutor * m_systemCommandExecutor
void timeUpdated(const QString &currentDate, const QString &currentTime, const QString &currentDay)
bool m_ownSystemCommandExecutor
QTimer & getStatusTimer()
bool m_ownSystemInfoProvider
void updateSystemStatus()
Updates the system status.
IBatteryController * m_batteryController
SystemManager(IBatteryController *batteryController=nullptr, ISystemInfoProvider *systemInfoProvider=nullptr, ISystemCommandExecutor *systemCommandExecutor=nullptr, QObject *parent=nullptr)
Constructor for the SystemManager class.
void shutdown()
Shuts down the SystemManager object.
ISystemInfoProvider * m_systemInfoProvider
void temperatureUpdated(const QString &temperature)
void updateTime()
Updates the current time.
bool m_ownBatteryController
void initialize()
Initializes the SystemManager object.