Commit 131f2e30 authored by Martin Sustrik's avatar Martin Sustrik

subscribe API removed

parent 059beca5
...@@ -41,7 +41,6 @@ int main (int argc, const char *argv []) ...@@ -41,7 +41,6 @@ int main (int argc, const char *argv [])
zmq::context_t ctx (1, 1); zmq::context_t ctx (1, 1);
zmq::socket_t s (ctx, ZMQ_SUB); zmq::socket_t s (ctx, ZMQ_SUB);
s.connect (chatroom_out_address); s.connect (chatroom_out_address);
s.subscribe ("*");
while (true) { while (true) {
......
...@@ -172,9 +172,6 @@ ZMQ_EXPORT int zmq_bind (void *s, const char *addr); ...@@ -172,9 +172,6 @@ ZMQ_EXPORT int zmq_bind (void *s, const char *addr);
// Connect the socket to a particular address. // Connect the socket to a particular address.
ZMQ_EXPORT int zmq_connect (void *s, const char *addr); ZMQ_EXPORT int zmq_connect (void *s, const char *addr);
// Subscribe for the subset of messages identified by 'criteria' argument.
ZMQ_EXPORT int zmq_subscribe (void *s, const char *criteria);
// Send the message 'msg' to the socket 's'. 'flags' argument can be // Send the message 'msg' to the socket 's'. 'flags' argument can be
// combination of following values: // combination of following values:
// ZMQ_NOBLOCK - if message cannot be sent, return immediately. // ZMQ_NOBLOCK - if message cannot be sent, return immediately.
......
...@@ -260,12 +260,6 @@ namespace zmq ...@@ -260,12 +260,6 @@ namespace zmq
} }
} }
inline void subscribe (const char *criteria_)
{
int rc = zmq_subscribe (ptr, criteria_);
assert (rc == 0);
}
inline int send (message_t &msg_, int flags_ = 0) inline int send (message_t &msg_, int flags_ = 0)
{ {
int rc = zmq_send (ptr, &msg_, flags_); int rc = zmq_send (ptr, &msg_, flags_);
......
...@@ -147,11 +147,6 @@ int zmq::socket_base_t::connect (const char *addr_) ...@@ -147,11 +147,6 @@ int zmq::socket_base_t::connect (const char *addr_)
return 0; return 0;
} }
int zmq::socket_base_t::subscribe (const char *criteria_)
{
zmq_assert (false);
}
int zmq::socket_base_t::send (struct zmq_msg *msg_, int flags_) int zmq::socket_base_t::send (struct zmq_msg *msg_, int flags_)
{ {
zmq_assert (false); zmq_assert (false);
......
...@@ -41,7 +41,6 @@ namespace zmq ...@@ -41,7 +41,6 @@ namespace zmq
virtual int setsockopt (int option_, void *optval_, size_t optvallen_); virtual int setsockopt (int option_, void *optval_, size_t optvallen_);
virtual int bind (const char *addr_); virtual int bind (const char *addr_);
virtual int connect (const char *addr_); virtual int connect (const char *addr_);
virtual int subscribe (const char *criteria_);
virtual int send (struct zmq_msg *msg_, int flags_); virtual int send (struct zmq_msg *msg_, int flags_);
virtual int flush (); virtual int flush ();
virtual int recv (struct zmq_msg *msg_, int flags_); virtual int recv (struct zmq_msg *msg_, int flags_);
......
...@@ -208,11 +208,6 @@ int zmq_connect (void *s_, const char *addr_) ...@@ -208,11 +208,6 @@ int zmq_connect (void *s_, const char *addr_)
return (((zmq::socket_base_t*) s_)->connect (addr_)); return (((zmq::socket_base_t*) s_)->connect (addr_));
} }
int zmq_subscribe (void *s_, const char *criteria_)
{
return (((zmq::socket_base_t*) s_)->subscribe (criteria_));
}
int zmq_send (void *s_, zmq_msg *msg_, int flags_) int zmq_send (void *s_, zmq_msg *msg_, int flags_)
{ {
return (((zmq::socket_base_t*) s_)->send (msg_, flags_)); return (((zmq::socket_base_t*) s_)->send (msg_, flags_));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment