Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
L
libzmq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
libzmq
Commits
603cd1db
Commit
603cd1db
authored
Jun 20, 2016
by
KIU Shueng Chuan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
change event monitoring functions to use zmq::fd_t
parent
5eb6fc3b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
13 deletions
+13
-13
socket_base.cpp
src/socket_base.cpp
+6
-6
socket_base.hpp
src/socket_base.hpp
+7
-7
No files found.
src/socket_base.cpp
View file @
603cd1db
...
...
@@ -1714,7 +1714,7 @@ int zmq::socket_base_t::monitor (const char *addr_, int events_)
return
rc
;
}
void
zmq
::
socket_base_t
::
event_connected
(
const
std
::
string
&
addr_
,
in
t
fd_
)
void
zmq
::
socket_base_t
::
event_connected
(
const
std
::
string
&
addr_
,
zmq
::
fd_
t
fd_
)
{
if
(
monitor_events
&
ZMQ_EVENT_CONNECTED
)
monitor_event
(
ZMQ_EVENT_CONNECTED
,
fd_
,
addr_
);
...
...
@@ -1732,7 +1732,7 @@ void zmq::socket_base_t::event_connect_retried (const std::string &addr_, int in
monitor_event
(
ZMQ_EVENT_CONNECT_RETRIED
,
interval_
,
addr_
);
}
void
zmq
::
socket_base_t
::
event_listening
(
const
std
::
string
&
addr_
,
in
t
fd_
)
void
zmq
::
socket_base_t
::
event_listening
(
const
std
::
string
&
addr_
,
zmq
::
fd_
t
fd_
)
{
if
(
monitor_events
&
ZMQ_EVENT_LISTENING
)
monitor_event
(
ZMQ_EVENT_LISTENING
,
fd_
,
addr_
);
...
...
@@ -1744,7 +1744,7 @@ void zmq::socket_base_t::event_bind_failed (const std::string &addr_, int err_)
monitor_event
(
ZMQ_EVENT_BIND_FAILED
,
err_
,
addr_
);
}
void
zmq
::
socket_base_t
::
event_accepted
(
const
std
::
string
&
addr_
,
in
t
fd_
)
void
zmq
::
socket_base_t
::
event_accepted
(
const
std
::
string
&
addr_
,
zmq
::
fd_
t
fd_
)
{
if
(
monitor_events
&
ZMQ_EVENT_ACCEPTED
)
monitor_event
(
ZMQ_EVENT_ACCEPTED
,
fd_
,
addr_
);
...
...
@@ -1756,7 +1756,7 @@ void zmq::socket_base_t::event_accept_failed (const std::string &addr_, int err_
monitor_event
(
ZMQ_EVENT_ACCEPT_FAILED
,
err_
,
addr_
);
}
void
zmq
::
socket_base_t
::
event_closed
(
const
std
::
string
&
addr_
,
in
t
fd_
)
void
zmq
::
socket_base_t
::
event_closed
(
const
std
::
string
&
addr_
,
zmq
::
fd_
t
fd_
)
{
if
(
monitor_events
&
ZMQ_EVENT_CLOSED
)
monitor_event
(
ZMQ_EVENT_CLOSED
,
fd_
,
addr_
);
...
...
@@ -1768,14 +1768,14 @@ void zmq::socket_base_t::event_close_failed (const std::string &addr_, int err_)
monitor_event
(
ZMQ_EVENT_CLOSE_FAILED
,
err_
,
addr_
);
}
void
zmq
::
socket_base_t
::
event_disconnected
(
const
std
::
string
&
addr_
,
in
t
fd_
)
void
zmq
::
socket_base_t
::
event_disconnected
(
const
std
::
string
&
addr_
,
zmq
::
fd_
t
fd_
)
{
if
(
monitor_events
&
ZMQ_EVENT_DISCONNECTED
)
monitor_event
(
ZMQ_EVENT_DISCONNECTED
,
fd_
,
addr_
);
}
// Send a monitor event
void
zmq
::
socket_base_t
::
monitor_event
(
int
event_
,
int
value_
,
const
std
::
string
&
addr_
)
void
zmq
::
socket_base_t
::
monitor_event
(
int
event_
,
int
ptr_t
value_
,
const
std
::
string
&
addr_
)
{
if
(
monitor_socket
)
{
// Send event in first frame
...
...
src/socket_base.hpp
View file @
603cd1db
...
...
@@ -123,16 +123,16 @@ namespace zmq
int
monitor
(
const
char
*
endpoint_
,
int
events_
);
void
event_connected
(
const
std
::
string
&
addr_
,
in
t
fd_
);
void
event_connected
(
const
std
::
string
&
addr_
,
zmq
::
fd_
t
fd_
);
void
event_connect_delayed
(
const
std
::
string
&
addr_
,
int
err_
);
void
event_connect_retried
(
const
std
::
string
&
addr_
,
int
interval_
);
void
event_listening
(
const
std
::
string
&
addr_
,
in
t
fd_
);
void
event_listening
(
const
std
::
string
&
addr_
,
zmq
::
fd_
t
fd_
);
void
event_bind_failed
(
const
std
::
string
&
addr_
,
int
err_
);
void
event_accepted
(
const
std
::
string
&
addr_
,
in
t
fd_
);
void
event_accepted
(
const
std
::
string
&
addr_
,
zmq
::
fd_
t
fd_
);
void
event_accept_failed
(
const
std
::
string
&
addr_
,
int
err_
);
void
event_closed
(
const
std
::
string
&
addr_
,
in
t
fd_
);
void
event_close_failed
(
const
std
::
string
&
addr_
,
int
fd
_
);
void
event_disconnected
(
const
std
::
string
&
addr_
,
in
t
fd_
);
void
event_closed
(
const
std
::
string
&
addr_
,
zmq
::
fd_
t
fd_
);
void
event_close_failed
(
const
std
::
string
&
addr_
,
int
err
_
);
void
event_disconnected
(
const
std
::
string
&
addr_
,
zmq
::
fd_
t
fd_
);
protected
:
...
...
@@ -177,7 +177,7 @@ namespace zmq
void
process_destroy
();
// Socket event data dispatch
void
monitor_event
(
int
event_
,
int
value_
,
const
std
::
string
&
addr_
);
void
monitor_event
(
int
event_
,
int
ptr_t
value_
,
const
std
::
string
&
addr_
);
// Monitor socket cleanup
void
stop_monitor
(
bool
send_monitor_stopped_event_
=
true
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment