mirror of
https://github.com/zeromq/libzmq.git
synced 2025-11-11 09:05:35 +01:00
Code cleanup
- limit visibility of pending_connection_t - add const qualifiers
This commit is contained in:
18
src/ctx.hpp
18
src/ctx.hpp
@@ -51,13 +51,6 @@ namespace zmq
|
||||
options_t options;
|
||||
};
|
||||
|
||||
struct pending_connection_t
|
||||
{
|
||||
endpoint_t endpoint;
|
||||
pipe_t* connect_pipe;
|
||||
pipe_t* bind_pipe;
|
||||
};
|
||||
|
||||
// Context object encapsulates all the global state associated with
|
||||
// the library.
|
||||
|
||||
@@ -109,7 +102,8 @@ namespace zmq
|
||||
int register_endpoint (const char *addr_, endpoint_t &endpoint_);
|
||||
void unregister_endpoints (zmq::socket_base_t *socket_);
|
||||
endpoint_t find_endpoint (const char *addr_);
|
||||
void pend_connection (const char *addr_, pending_connection_t &pending_connection_);
|
||||
void pend_connection (const std::string &addr_,
|
||||
const endpoint_t &endpoint_, pipe_t **pipes_);
|
||||
void connect_pending (const char *addr_, zmq::socket_base_t *bind_socket_);
|
||||
|
||||
enum {
|
||||
@@ -121,6 +115,12 @@ namespace zmq
|
||||
|
||||
private:
|
||||
|
||||
struct pending_connection_t
|
||||
{
|
||||
endpoint_t endpoint;
|
||||
pipe_t* connect_pipe;
|
||||
pipe_t* bind_pipe;
|
||||
};
|
||||
|
||||
// Used to check whether the object is a context.
|
||||
uint32_t tag;
|
||||
@@ -196,7 +196,7 @@ namespace zmq
|
||||
pid_t pid;
|
||||
#endif
|
||||
enum side { connect_side, bind_side };
|
||||
void connect_inproc_sockets(zmq::socket_base_t *bind_socket_, options_t& bind_options, pending_connection_t &pending_connection_, side side_);
|
||||
void connect_inproc_sockets(zmq::socket_base_t *bind_socket_, options_t& bind_options, const pending_connection_t &pending_connection_, side side_);
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user