Go to the documentation of this file.00001
00008
00009
00010
00011
00012 #ifndef LISTENER_NODE_HPP_
00013 #define LISTENER_NODE_HPP_
00014
00015
00016
00017
00018
00019 #ifndef Q_MOC_RUN
00020 #include <ros/ros.h>
00021 #include "../common/qnode.hpp"
00022 #endif
00023
00024 #include <std_msgs/String.h>
00025 #include <string>
00026
00027
00028
00029
00030
00031 class Listener : public QNode {
00032
00033 public:
00034 Listener(int argc, char** argv);
00035 virtual ~Listener() {}
00036 void run();
00037 void ros_comms_init();
00038 private:
00039 void chatterCallback(const std_msgs::String::ConstPtr &msg);
00040 ros::Subscriber chatter_subscriber;
00041 };
00042
00043 #endif