class CZTop::Poller::ZMQ::PollerEvent
This represents a zmq_poller_event_t
as in:
typedef struct zmq_poller_event_t { void *socket; int fd; void *user_data; short events; } zmq_poller_event_t;
Public Instance Methods
readable?()
click to toggle source
@return [Boolean] whether the socket is readable
# File lib/cztop/poller/zmq.rb, line 35 def readable? (self[:events] & POLLIN).positive? end
writable?()
click to toggle source
@return [Boolean] whether the socket is writable
# File lib/cztop/poller/zmq.rb, line 41 def writable? (self[:events] & POLLOUT).positive? end