| 1 | #pragma once |
| 2 | |
| 3 | #include <Eigen/Core> |
| 4 | #include <string> |
| 5 | |
| 6 | namespace gtsam { |
| 7 | |
| 8 | /** |
| 9 | * \brief This is the base class for all measurement types. |
| 10 | */ |
| 11 | class Measurement { |
| 12 | public: |
| 13 | EIGEN_MAKE_ALIGNED_OPERATOR_NEW |
| 14 | size_t dt; ///< Time since the last message of this type (nanoseconds). |
| 15 | size_t time; ///< ROS time message recieved (nanoseconds). |
| 16 | ///< The type of message (to enable dynamic/static casting). |
| 17 | std::string type; |
| 18 | |
| 19 | Measurement() : dt(0), time(0), type("UNDEFINED" ) {} |
| 20 | Measurement(std::string _type) : dt(0), time(0), type(_type) {} |
| 21 | |
| 22 | virtual ~Measurement() {} |
| 23 | }; |
| 24 | |
| 25 | } // namespace gtsam |
| 26 | |