-
Notifications
You must be signed in to change notification settings - Fork 1
/
Loader.hpp
40 lines (34 loc) · 922 Bytes
/
Loader.hpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
/**************************************************************************
** Code written by Hesam Gholami.
**
** Email: [email protected]
** Website: http://hesam.org
**
** This file created in 12.
**************************************************************************/
#ifndef LOADER_HPP
#define LOADER_HPP
#include "DumpTruck.hpp"
#include "LoadingQueue.hpp"
#include "WeighQueue.hpp"
#include <QObject>
class Loader : public QObject
{
Q_OBJECT
public:
explicit Loader(QObject *parent = nullptr);
bool addTruck(DumpTruck *truck);
bool canAddTruck();
bool isLoader1Busy();
bool isLoader2Busy();
QString getCount() const;
void processEvents(LoadingQueue &loadingQueue, WeighQueue &weighQueue);
void releaseLoader1();
void releaseLoader2();
signals:
public slots:
private:
DumpTruck *loader1 = nullptr;
DumpTruck *loader2 = nullptr;
};
#endif // LOADER_HPP