20 #include <boost/shared_ptr.hpp>
27 #include "mujincontrollerclient/config.h"
34 ZmqSubscriber(
const std::string& host,
const unsigned int port);
38 void _InitializeSocket(boost::shared_ptr<zmq::context_t> context);
39 void _DestroySocket();
56 bool Publish(
const std::string& messagestr);
59 void _InitializeSocket(boost::shared_ptr<zmq::context_t> context);
60 void _DestroySocket();
73 ZmqClient(
const std::string& host,
const unsigned int port);
76 std::string Call(
const std::string& msg,
const double timeout=5.0);
79 void _InitializeSocket(boost::shared_ptr<zmq::context_t> context);
80 void _DestroySocket();
97 virtual unsigned int Recv(std::string& data,
long timeout=0);
98 virtual void Send(
const std::string& message);
101 virtual void _InitializeSocket(boost::shared_ptr<zmq::context_t> context);
102 virtual void _DestroySocket();
114 #endif // MUJIN_ZMQ_H