gtsam/tests/Measurement.h

26 lines
604 B
C
Raw Permalink Normal View History

#pragma once
#include <Eigen/Core>
#include <string>
2020-12-15 03:32:04 +08:00
namespace gtsam {
2020-12-15 03:32:04 +08:00
/**
* \brief This is the base class for all measurement types.
*/
class Measurement {
2020-12-15 03:32:04 +08:00
public:
EIGEN_MAKE_ALIGNED_OPERATOR_NEW
2020-12-15 03:32:04 +08:00
size_t dt; ///< Time since the last message of this type (nanoseconds).
size_t time; ///< ROS time message recieved (nanoseconds).
///< The type of message (to enable dynamic/static casting).
std::string type;
Measurement() : dt(0), time(0), type("UNDEFINED") {}
Measurement(std::string _type) : dt(0), time(0), type(_type) {}
virtual ~Measurement() {}
};
2020-12-15 03:32:04 +08:00
} // namespace gtsam