|
cpp-msgpack-rpc 0.2.0
An RPC library implementing MessagePack RPC.
|
Class of lists of connections. More...
#include <msgpack_rpc/transport/connection_list.h>
Public Member Functions | |
| ConnectionList ()=default | |
| Constructor. | |
| void | append (const std::shared_ptr< Connection > &connection) |
| Add a connection. | |
| void | async_close_all () |
| Asynchronously close all connections. | |
| void | remove (Connection *connection) |
| Remove a connection. | |
| void | remove (const std::shared_ptr< Connection > &connection) |
| Remove a connection. | |
Private Attributes | |
| std::unordered_map< Connection *, std::weak_ptr< Connection > > | list_ {} |
| List of connections. | |
| std::mutex | mutex_ {} |
| Mutex. | |
Class of lists of connections.
| Connection | Type of connections. |
Definition at line 34 of file connection_list.h.
|
inline |
Add a connection.
| [in] | connection | Connection. |
Definition at line 46 of file connection_list.h.
|
inline |
Asynchronously close all connections.
Definition at line 73 of file connection_list.h.
|
inline |
Remove a connection.
| [in] | connection | Connection. |
Definition at line 65 of file connection_list.h.
|
inline |
Remove a connection.
| [in] | connection | Connection. |
Definition at line 56 of file connection_list.h.
|
private |
List of connections.
Definition at line 85 of file connection_list.h.
|
private |
Mutex.
Definition at line 88 of file connection_list.h.