bitrl & cuberl Documentation
Simulation engine for reinforcement learning agents
Loading...
Searching...
No Matches
waypoint.h
Go to the documentation of this file.
1#ifndef WAYPOINT_H
2#define WAYPOINT_H
3
5#include "bitrl/bitrl_types.h"
7namespace bitrl
8{
9namespace utils
10{
11namespace trajectory
12{
13
15
19template <int dim, typename Data> class WayPoint : public GeomPoint<dim>
20{
21 public:
22 typedef Data data_type;
23
27 WayPoint();
28
32 WayPoint(const GeomPoint<dim> &p, uint_t id, const data_type &data_ = data_type());
33
37 uint_t get_id() const { return id_; }
38
42 data_type &get_data() { return data_; }
43
47 const data_type &get_data() const { return data_; }
48
52 bool is_active() const { return is_active_point_; }
53
54 private:
55 uint_t id_;
56 data_type data_;
57 bool is_active_point_;
58};
59
60template <int dim, typename Data>
61WayPoint<dim, Data>::WayPoint(const GeomPoint<dim> &p, uint_t id,
62 const typename WayPoint<dim, Data>::data_type &data)
63 : GeomPoint<dim>(p), id_(id), data_(data), is_active_point_(true)
64{
65}
66
67template <int dim, typename Data>
69{
70}
71} // namespace trajectory
72} // namespace utils
73} // namespace bitrl
74
75#endif
A class that describes a point with spacedim spatial dimension space.
Definition geom_point.h:22
Helper class to represent a waypoint.
Definition waypoint.h:20
data_type & get_data()
Writable reference to the data.
Definition waypoint.h:42
const data_type & get_data() const
Read reference to the data.
Definition waypoint.h:47
WayPoint()
Definition waypoint.h:68
Data data_type
Definition waypoint.h:22
uint_t get_id() const
Return the id of the point.
Definition waypoint.h:37
WayPoint(const GeomPoint< dim > &p, uint_t id, const data_type &data_=data_type())
bool is_active() const
Returns true if the waypoint is active.
Definition waypoint.h:52
OutT resolve(const std::string &name, const std::map< std::string, std::any > &input)
Definition std_map_utils.h:25
Definition bitrl_consts.h:14
std::size_t uint_t
uint_t
Definition bitrl_types.h:43