Computer Assited Medical Intervention Tool Kit  version 5.0
MonitoringDriver.h
Go to the documentation of this file.
1 /*****************************************************************************
2  * $CAMITK_LICENCE_BEGIN$
3  *
4  * CamiTK - Computer Assisted Medical Intervention ToolKit
5  * (c) 2001-2021 Univ. Grenoble Alpes, CNRS, Grenoble INP, TIMC, 38000 Grenoble, France
6  *
7  * Visit http://camitk.imag.fr for more information
8  *
9  * This file is part of CamiTK.
10  *
11  * CamiTK is free software: you can redistribute it and/or modify
12  * it under the terms of the GNU Lesser General Public License version 3
13  * only, as published by the Free Software Foundation.
14  *
15  * CamiTK is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18  * GNU Lesser General Public License version 3 for more details.
19  *
20  * You should have received a copy of the GNU Lesser General Public License
21  * version 3 along with CamiTK. If not, see <http://www.gnu.org/licenses/>.
22  *
23  * $CAMITK_LICENCE_END$
24  ****************************************************************************/
25 
26 #ifndef MONITORINGSIMULATIONDRIVER_H
27 #define MONITORINGSIMULATIONDRIVER_H
28 
29 #include <QObject>
30 #include <qtimer.h>
31 
32 #include "MonitoringGuiManager.h"
33 
41 class MonitoringDriver : public QObject {
42 
43  Q_OBJECT
44 
45 public:
46 
49 
51  ~MonitoringDriver() override;
52 
53  void init();
54 
56  void startTimer();
57 
59  void stopTimer();
60 
62  bool isTimerActive();
63 
64 signals:
65 
67  void doOneStep();
68 
69 public slots:
70 
72  void play();
73 
74 private:
77 
79  QTimer* timer;
80 
81 
82 
83 };
84 
85 #endif
MonitoringDriver.h
MonitoringDriver::startTimer
void startTimer()
starts the timer that will repeatedly call play and emit doOneStep
Definition: MonitoringDriver.cpp:68
MonitoringDriver::~MonitoringDriver
~MonitoringDriver() override
Destructor.
Definition: MonitoringDriver.cpp:39
MonitoringDriver
TODO Comment class here.
Definition: MonitoringDriver.h:41
MonitoringDriver::isTimerActive
bool isTimerActive()
is the timer currently running
Definition: MonitoringDriver.cpp:78
MonitoringDriver::stopTimer
void stopTimer()
stop the timer
Definition: MonitoringDriver.cpp:73
MonitoringDriver::doOneStep
void doOneStep()
signal call when one step is to be performed
MonitoringGuiManager
A GUI to manipulate mml documents.
Definition: MonitoringGuiManager.h:45
MonitoringDriver::timer
QTimer * timer
the simulation timer
Definition: MonitoringDriver.h:102
MonitoringGuiManager.h
MonitoringDriver::MonitoringDriver
MonitoringDriver(MonitoringGuiManager *guiManager)
Constructor.
Definition: MonitoringDriver.cpp:33
MonitoringDriver::guiManager
MonitoringGuiManager * guiManager
the monitoring manager
Definition: MonitoringDriver.h:99
MonitoringDriver::play
void play()
Slot called when at each timer tick (i.e. after the same interval of time)
Definition: MonitoringDriver.cpp:56
MonitoringDriver::init
void init()
Definition: MonitoringDriver.cpp:46