summaryrefslogtreecommitdiffstats
path: root/src/Detector/Detector.h
blob: 16f946a2291dd079b15513c5443b797ca8a6e2f2 (plain)
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
/*
 * Copyright 2016 Tobias Frust
 *
 * Detector.h
 *
 *  Created on: 30.06.2016
 *      Author: Tobias Frust
 */

#ifndef DETECTOR_H_
#define DETECTOR_H_

#include "../DetectorModule/DetectorModule.h"

#include <vector>
#include <thread>

class Detector {
public:
   Detector(const std::string& address, const std::string& configPath, const unsigned int timeIntervall, const int packetSize);

   auto run() -> void;
private:
   std::vector<DetectorModule> modules_;

   std::vector<std::thread> moduleThreads_;

   unsigned int timeIntervall_;
   int numberOfDetectorModules_;

   auto readConfig(const std::string& configFile) -> bool;

};

#endif /* DETECTOR_H_ */