CARMA C++
MonitorDataTableFinisherThread.h
Go to the documentation of this file.
1 #ifndef CARMA_DBMS_MONITORDATATABLEFINISHERTHREAD_H
2 #define CARMA_DBMS_MONITORDATATABLEFINISHERTHREAD_H
3 
16 
17 #include <boost/thread.hpp>
18 #include <string>
19 
20 namespace carma {
21 namespace dbms {
22 
23  class DBConnection;
24 
30 
31 public:
32 
40  (const std::string& threadName,
41  const carma::dbms::DBConnection * const dbc,
42  const std::string& tableName,
43  const carma::dbms::MonitorAverageType& averageType);
44 
46 
47  bool isFinished() const;
48 
52  void operator()();
53 
54 protected:
55 
61  std::string tableName_;
62 
63  boost::thread thread_;
64  bool finished_;
65  mutable boost::mutex finishedMutex_;
66 };
67 
68 
69 }}
70 
71 #endif // CARMA_DBMS_MONITORDATAFINISHERTHREAD_H
72 
MonitorDataTableFinisherThread(const std::string &threadName, const carma::dbms::DBConnection *const dbc, const std::string &tableName, const carma::dbms::MonitorAverageType &averageType)
constructor
void operator()()
the actions to take to finish up with the table
const carma::dbms::DBConnection * dbc_
disallow default constructor
Thread class for executing commands on a monitor data table after it has been populated.
relationships between the monitor and dbms systems
MonitorAverageType
average type of the monitor[point,data file,table]
an abstract class from which database queries may be launched.
Definition: DBConnection.h:46