forked from rock-core/drivers-orogen-transformer
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathBroadcastTypes.hpp
49 lines (40 loc) · 1.59 KB
/
BroadcastTypes.hpp
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
42
43
44
45
46
47
48
49
#ifndef TRANSFORMER_BROADCAST_TYPES_HPP
#define TRANSFORMER_BROADCAST_TYPES_HPP
#include <string>
#include <base/samples/RigidBodyState.hpp>
#include <vector>
namespace transformer {
struct PortFrameAssociation
{
std::string task;
std::string port;
std::string frame;
PortFrameAssociation() {}
PortFrameAssociation(std::string const& task, std::string const& port,
std::string const& frame)
: task(task), port(port) , frame(frame) {}
bool operator == (PortFrameAssociation const& other) const
{ return task == other.task && port == other.port && frame == other.frame; }
};
struct PortTransformationAssociation
{
std::string task;
std::string port;
std::string from_frame;
std::string to_frame;
PortTransformationAssociation() {}
PortTransformationAssociation(std::string const& task, std::string const& port,
std::string const& from_frame, std::string const& to_frame)
: task(task), port(port)
, from_frame(from_frame), to_frame(to_frame) {}
bool operator == (PortTransformationAssociation const& other) const
{ return task == other.task && port == other.port && from_frame == other.from_frame && to_frame == other.to_frame; }
};
struct ConfigurationState
{
std::vector<PortFrameAssociation> port_frame_associations;
std::vector<PortTransformationAssociation> port_transformation_associations;
std::vector<base::samples::RigidBodyState> static_transformations;
};
}
#endif