-
Notifications
You must be signed in to change notification settings - Fork 1
/
sjf.h
77 lines (71 loc) · 1.83 KB
/
sjf.h
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
#ifndef SJF_H
#define SJF_H
#include <QWidget>
#include <Sched.h>
void OpenSjfWindow();
namespace Ui {
class sjf;
}
class sjf : public QWidget
{
Q_OBJECT
public:
explicit sjf(QWidget *parent = 0);
~sjf();
private:
Ui::sjf *ui;
Ui::sjf *gUi;
void closeEvent(QCloseEvent *);
void ClearFCFSAll();
int iBurstIndex;
int iArrivalIndex;
int iRemovalIndex;
bool bCPUBusy;
bool bSjfStart;
bool bSjfPause;
bool bSjfReset;
int iProcInRQ;
int iPreemptiveness;
int iProcessInSystem;
QTimer *Timer;
void DeleteTimer();
void ClearProcessLabels();
void ClearBTLabels();
void ClearATLabels();
void ClearRQLabels();
void ClearCPULabels();
void ClearBTTimeLabel();
void ClearAllStructure();
void ClearStructureForStop();
void ResetSimulator();
void ProcessDisplayOnHMi(ProcessDef *);
void UpdateColourWhenInRQ();
void UpdateColourWhenInCPU();
void UpdateColourWhenInNormal();
void PutIntoTheCPU();
void Dispatcher();
void ClearLabelColour();
void UpdateDisplayRQ();
void UpdateReadyQueue();
void FillDisplayRQ(ProcessDef);
void CreateTimer();
void DisplayMessage(int);
void DisableWidgetsWhenStart();
void EnableWidgetWhenStop();
void DisableWidgetsBeforeProcessCreation();
void EnableWidgetAfterProcessCreation();
private slots:
void on_Preemptiveness_highlighted(int index);
void CallDispatcher();
void on_ResetSim_clicked();
void on_StepSim_clicked();
void on_PauseSim_clicked();
void on_StopSim_clicked();
void on_StartSim_clicked();
void on_ArrivalTime_textChanged(QString );
void on_BurstTime_textChanged(QString );
void on_ChangeAT_highlighted(int index);
void on_ChangeBT_highlighted(int index);
void on_CreateProcess_clicked();
};
#endif // SJF_H