-
Notifications
You must be signed in to change notification settings - Fork 22
/
mapping_node.h
41 lines (31 loc) · 1.11 KB
/
mapping_node.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
#ifndef CSLIBS_MAPPING_NODE_H
#define CSLIBS_MAPPING_NODE_H
#include <cslibs_mapping/mapper/mapper.hpp>
#include <cslibs_mapping/publisher/publisher.hpp>
#include <cslibs_mapping/SaveMap.h>
#include <cslibs_plugins_data/data_provider.hpp>
namespace cslibs_mapping {
class MappingNode
{
public:
inline MappingNode();
inline ~MappingNode();
inline bool setup();
inline void start();
private:
inline bool saveMaps(cslibs_mapping::SaveMap::Request &request, cslibs_mapping::SaveMap::Response &response);
template <typename T>
using map_t = std::map<std::string, typename T::Ptr>;
using data_provider_t = cslibs_plugins_data::DataProvider;
using mapper_t = cslibs_mapping::mapper::Mapper;
using publisher_t = cslibs_mapping::publisher::Publisher;
using tf_listener_t = cslibs_math_ros::tf::TFListener;
ros::NodeHandle nh_;
ros::ServiceServer service_;
tf_listener_t::Ptr tf_;
map_t<data_provider_t> data_providers_;
map_t<mapper_t> mappers_;
map_t<publisher_t> publishers_;
};
}
#endif // CSLIBS_MAPPING_NODE_H