37 #include <std_msgs/Float32.h> 42 parent_(parent), start_time_(
ros::WallTime::now()),
43 is_publish_(false), is_enabled_(true)
66 std_msgs::Float32 ros_latest;
69 std_msgs::Float32 ros_average;
87 max_num_(max_num), buffer_(max_num)
121 for (
size_t i = 0; i <
buffer_.size(); i++) {
virtual void setIsEnabled(bool)
virtual void report(ros::WallDuration &duration)
void publish(const boost::shared_ptr< M > &message) const
virtual ~ScopedWallDurationReporter()
boost::circular_buffer< ros::WallDuration > buffer_
virtual void clearBuffer()
virtual ScopedWallDurationReporter reporter()
virtual size_t sampleNum()
ros::Publisher pub_average_
virtual double latestSec()
virtual void setIsPublish(bool)
ros::WallTime start_time_
ScopedWallDurationReporter(WallDurationTimer *parent)
WallDurationTimer(const int max_num)
ros::Publisher pub_latest_
WallDurationTimer * parent_