summaryrefslogtreecommitdiff
path: root/src/socket_base.cpp
diff options
context:
space:
mode:
authorMartin Sustrik <sustrik@250bpm.com>2010-12-04 23:14:38 +0100
committerMartin Sustrik <sustrik@250bpm.com>2010-12-04 23:14:38 +0100
commitc80e7b80cc726ca7c29493c2553c8d19792bb6e5 (patch)
tree9c740ee660e900766a6f7d7e8a48bb09a6b72c4b /src/socket_base.cpp
parentabc8b5e40c55deb96e7674b15629f2affa4eb92a (diff)
XPUB and XSUB socket types added.
These are just placeholders. At the moment XPUB behaves th same as PUB and XSUB as SUB. Signed-off-by: Martin Sustrik <sustrik@250bpm.com>
Diffstat (limited to 'src/socket_base.cpp')
-rw-r--r--src/socket_base.cpp11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/socket_base.cpp b/src/socket_base.cpp
index bfaacb7..2fe7bfd 100644
--- a/src/socket_base.cpp
+++ b/src/socket_base.cpp
@@ -46,6 +46,8 @@
#include "ctx.hpp"
#include "platform.hpp"
#include "likely.hpp"
+#include "uuid.hpp"
+
#include "pair.hpp"
#include "pub.hpp"
#include "sub.hpp"
@@ -55,7 +57,8 @@
#include "push.hpp"
#include "xreq.hpp"
#include "xrep.hpp"
-#include "uuid.hpp"
+#include "xpub.hpp"
+#include "xsub.hpp"
zmq::socket_base_t *zmq::socket_base_t::create (int type_, class ctx_t *parent_,
uint32_t tid_)
@@ -90,6 +93,12 @@ zmq::socket_base_t *zmq::socket_base_t::create (int type_, class ctx_t *parent_,
case ZMQ_PUSH:
s = new (std::nothrow) push_t (parent_, tid_);
break;
+ case ZMQ_XPUB:
+ s = new (std::nothrow) xpub_t (parent_, tid_);
+ break;
+ case ZMQ_XSUB:
+ s = new (std::nothrow) xsub_t (parent_, tid_);
+ break;
default:
errno = EINVAL;
return NULL;