Fawkes API  Fawkes Development Version
pcl_db_retrieve_thread.h
1 
2 /***************************************************************************
3  * pcl_db_retrieve_thread.h - Restore and retrieve point clouds from MongoDB
4  *
5  * Created: Thu Aug 22 12:04:15 2013
6  * Copyright 2012 Tim Niemueller [www.niemueller.de]
7  ****************************************************************************/
8 
9 /* This program is free software; you can redistribute it and/or modify
10  * it under the terms of the GNU General Public License as published by
11  * the Free Software Foundation; either version 2 of the License, or
12  * (at your option) any later version.
13  *
14  * This program is distributed in the hope that it will be useful,
15  * but WITHOUT ANY WARRANTY; without even the implied warranty of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17  * GNU Library General Public License for more details.
18  *
19  * Read the full text in the LICENSE.GPL file in the doc directory.
20  */
21 
22 #ifndef _PLUGINS_PERCEPTION_PCL_DB_RETRIEVE_PCL_DB_RETRIEVE_THREAD_H_
23 #define _PLUGINS_PERCEPTION_PCL_DB_RETRIEVE_PCL_DB_RETRIEVE_THREAD_H_
24 
25 #include "pcl_db_retrieve_pipeline.h"
26 
27 #include <aspect/blackboard.h>
28 #include <aspect/clock.h>
29 #include <aspect/configurable.h>
30 #include <aspect/logging.h>
31 #include <aspect/pointcloud.h>
32 #include <aspect/tf.h>
33 #include <core/threading/thread.h>
34 #include <pcl/point_cloud.h>
35 #include <pcl/point_types.h>
36 #include <plugins/mongodb/aspect/mongodb.h>
37 
38 namespace fawkes {
39 class PclDatabaseRetrieveInterface;
40 class BlackBoardOnMessageWaker;
41 } // namespace fawkes
42 
44  public fawkes::ClockAspect,
45  public fawkes::LoggingAspect,
48  public fawkes::MongoDBAspect,
51 {
52 public:
55 
56  virtual void init();
57  virtual void loop();
58  virtual void finalize();
59 
60  /** Stub to see name in backtrace for easier debugging. @see Thread::run() */
61 protected:
62  virtual void
63  run()
64  {
65  Thread::run();
66  }
67 
68 private: // members
69  fawkes::PclDatabaseRetrieveInterface *retrieve_if_;
71 
74 
77 
78  std::string cfg_database_;
79  std::string cfg_output_id_;
80  std::string cfg_original_id_;
81 
84 };
85 
86 #endif
fawkes::MongoDBAspect
Definition: mongodb.h:41
fawkes::RefPtr
RefPtr<> is a reference-counting shared smartpointer.
Definition: refptr.h:55
PointCloudDBRetrieveThread::run
virtual void run()
Stub to see name in backtrace for easier debugging.
Definition: pcl_db_retrieve_thread.h:62
PointCloudDBRetrieveThread::finalize
virtual void finalize()
Finalize the thread.
Definition: pcl_db_retrieve_thread.cpp:84
PointCloudDBRetrieveThread::PointCloudDBRetrieveThread
PointCloudDBRetrieveThread()
Constructor.
Definition: pcl_db_retrieve_thread.cpp:34
PointCloudDBRetrieveThread::loop
virtual void loop()
Code to execute in the thread.
Definition: pcl_db_retrieve_thread.cpp:102
PointCloudDBRetrieveThread::init
virtual void init()
Initialize the thread.
Definition: pcl_db_retrieve_thread.cpp:45
PointCloudDBRetrievePipeline< pcl::PointXYZ >
fawkes::BlackBoardAspect
Definition: blackboard.h:36
fawkes::PointCloudAspect
Definition: pointcloud.h:36
fawkes
fawkes::LoggingAspect
Definition: logging.h:36
fawkes::TransformAspect
Definition: tf.h:41
pcl::PointCloud
Definition: pointcloud.h:36
PointCloudDBRetrieveThread
Definition: pcl_db_retrieve_thread.h:42
fawkes::Thread
Definition: thread.h:44
fawkes::BlackBoardOnMessageWaker
Definition: on_message_waker.h:39
PointCloudDBRetrieveThread::~PointCloudDBRetrieveThread
virtual ~PointCloudDBRetrieveThread()
Destructor.
Definition: pcl_db_retrieve_thread.cpp:40
fawkes::ConfigurableAspect
Definition: configurable.h:36
fawkes::ClockAspect
Definition: clock.h:38