I'm working with the ZMQ binding for Node.js and apparently I cannot access the options of the socket. Here's how I create sockets for PULL and PUSH:
var sender = zmq.socket('push');
var receiver = zmq.socket('pull');
Then it's quite easy to setup a messaging system, but I would like to access _ioevents but it's kind of hard to understand how can I access that option through the socket itself. My aim is to get to the ZMQ_POLLIN and ZMQ_POLLOUT statuses described here.
The content of the PULL socket is the following:
{ type: 'pull',
_zmq: { state: 0, onReady: [Function] },
_outgoing: [],
_shouldFlush: true,
_events: { message: [Function], EINTR: [Function] } }
Which is of no help.
Thanks
I realised I was asking the wrong object the question. The object containing the ZMQ_POLLIN and ZMQ_POLLOUT statuses is zmq created through var zmq = require('zmq'); which was used to create the sender and receiver objects.
By simply doing zmq.ZMQ_POLLIN I could access the flags. I still have to figure out what their mean is though.