ZMQ
class ZMQ (View source)
Class ZMQ
Constants
| SOCKET_PAIR |
Exclusive pair pattern |
| SOCKET_PUB |
Publisher socket |
| SOCKET_SUB |
Subscriber socket |
| SOCKET_REQ |
Request socket |
| SOCKET_REP |
Reply socket |
| SOCKET_XREQ |
Alias for SOCKET_DEALER |
| SOCKET_XREP |
Alias for SOCKET_ROUTER |
| SOCKET_PUSH |
Pipeline upstream push socket |
| SOCKET_PULL |
Pipeline downstream pull socket |
| SOCKET_ROUTER |
Extended REP socket that can route replies to requesters |
| SOCKET_DEALER |
Extended REQ socket that load balances to all connected peers |
| SOCKET_XPUB |
Similar to SOCKET_PUB, except you can receive subscriptions as messages. The subscription message is 0 (unsubscribe) or 1 (subscribe) followed by the topic. |
| SOCKET_XSUB |
Similar to SOCKET_SUB, except you can send subscriptions as messages. See SOCKET_XPUB for format. |
| SOCKET_STREAM |
Used to send and receive TCP data from a non-ØMQ peer. Available if compiled against ZeroMQ 4.x or higher. |
| SOCKOPT_HWM |
The high water mark for inbound and outbound messages is a hard
limit on the maximum number of outstanding messages ØMQ shall queue in memory
for any single peer that the specified socket is communicating with. Setting this option on a socket will only affect connections made after the option has been set. On ZeroMQ 3.x this is a wrapper for setting both SNDHWM and RCVHWM. |
| SOCKOPT_SNDHWM |
The ZMQ_SNDHWM option shall set the high water mark for outbound messages on the specified socket. Available if compiled against ZeroMQ 3.x or higher. |
| SOCKOPT_RCVHWM |
The ZMQ_SNDHWM option shall set the high water mark for inbound messages on the specified socket. Available if compiled against ZeroMQ 3.x or higher. |
| SOCKOPT_AFFINITY |
Set I/O thread affinity |
| SOCKOPT_IDENTITY |
Set socket identity |
| SOCKOPT_SUBSCRIBE |
Establish message filter. Valid for subscriber socket |
| SOCKOPT_UNSUBSCRIBE |
Remove message filter. Valid for subscriber socket |
| SOCKOPT_RATE |
Set rate for multicast sockets (pgm) (Value: int >= 0) |
| SOCKOPT_RECOVERY_IVL |
Set multicast recovery interval (Value: int >= 0) |
| SOCKOPT_RECONNECT_IVL |
Set the initial reconnection interval (Value: int >= 0) |
| SOCKOPT_RECONNECT_IVL_MAX |
Set the max reconnection interval (Value: int >= 0) |
| SOCKOPT_MCAST_LOOP |
Control multicast loopback (Value: int >= 0) |
| SOCKOPT_SNDBUF |
Set kernel transmit buffer size (Value: int >= 0) |
| SOCKOPT_RCVBUF |
Set kernel receive buffer size (Value: int >= 0) |
| SOCKOPT_RCVMORE |
Receive multi-part messages |
| SOCKOPT_TYPE |
Get the socket type. Valid for getSockOpt |
| SOCKOPT_LINGER |
The linger value of the socket. Specifies how long the socket blocks trying flush messages after it has been closed |
| SOCKOPT_BACKLOG |
The SOCKOPT_BACKLOG option shall set the maximum length of the queue of outstanding peer connections
for the specified socket; this only applies to connection-oriented transports. |
| SOCKOPT_MAXMSGSIZE |
Limits the maximum size of the inbound message. Value -1 means no limit. Available if compiled against ZeroMQ 3.x or higher |
| SOCKOPT_SNDTIMEO |
Sets the timeout for send operation on the socket. Value -1 means no limit. Available if compiled against ZeroMQ 3.x or higher |
| SOCKOPT_RCVTIMEO |
Sets the timeout for receive operation on the socket. Value -1 means no limit. Available if compiled against ZeroMQ 3.x or higher |
| SOCKOPT_IPV4ONLY |
Disable IPV6 support if 1. Available if compiled against ZeroMQ 3.x |
| SOCKOPT_LAST_ENDPOINT |
Retrieve the last connected endpoint - for use with * wildcard ports. Available if compiled against ZeroMQ 3.x or higher |
| SOCKOPT_TCP_KEEPALIVE_IDLE |
Idle time for TCP keepalive. Available if compiled against ZeroMQ 3.x or higher |
| SOCKOPT_TCP_KEEPALIVE_CNT |
Count time for TCP keepalive. Available if compiled against ZeroMQ 3.x or higher |
| SOCKOPT_TCP_KEEPALIVE_INTVL |
Interval for TCP keepalive. Available if compiled against ZeroMQ 3.x or higher |
| SOCKOPT_DELAY_ATTACH_ON_CONNECT |
Set a CIDR string to match against incoming TCP connections. Available if compiled against ZeroMQ 3.x or higher |
| SOCKOPT_TCP_ACCEPT_FILTER |
Set a CIDR string to match against incoming TCP connections. Available if compiled against ZeroMQ 3.x or higher |
| SOCKOPT_XPUB_VERBOSE |
Set the XPUB to receive an application message on each instance of a subscription. Available if compiled against ZeroMQ 3.x or higher |
| SOCKOPT_ROUTER_RAW |
Sets the raw mode on the ROUTER, when set to 1. In raw mode when using tcp:// transport the socket will read and write without ZeroMQ framing. Available if compiled against ZeroMQ 4.0 or higher |
| SOCKOPT_IPV6 |
Enable IPV6. Available if compiled against ZeroMQ 4.0 or higher |
| CTXOPT_MAX_SOCKETS |
The socket limit for this context. Available if compiled against ZeroMQ 3.x or higher |
| POLL_IN |
Poll for incoming data |
| POLL_OUT |
Poll for outgoing data |
| deprecated MODE_NOBLOCK |
Non-blocking operation. |
| MODE_DONTWAIT |
Non-blocking operation |
| MODE_SNDMORE |
Send multi-part message |
| DEVICE_FORWARDER |
Forwarder device |
| DEVICE_QUEUE |
Queue device |
| DEVICE_STREAMER |
Streamer device |
| ERR_INTERNAL |
ZMQ extension internal error |
| ERR_EAGAIN |
Implies that the operation would block when ZMQ::MODE_DONTWAIT is used |
| ERR_ENOTSUP |
The operation is not supported by the socket type |
| ERR_EFSM |
The operation can not be executed because the socket is not in correct state |
| ERR_ETERM |
The context has been terminated |