|
jabberd14
1.6.2
|
connects two sockets to each other More...
#include <proxy65.h>
Public Member Functions | |
| connected_sockets (socks5stub *socket1, socks5stub *socket2, const std::string &identifier) | |
| ~connected_sockets () | |
| sigc::signal< void, connected_sockets * > & | event_closed () |
| size_t | get_forwarded_traffic () |
| const std::string & | get_identifier () |
connects two sockets to each other
| xmppd::proxy65::connected_sockets::connected_sockets | ( | socks5stub * | socket1, |
| socks5stub * | socket2, | ||
| const std::string & | identifier | ||
| ) |
create a new instance by connecting two sockets
| socket1 | the one socket that gets connected |
| socket2 | the other socket that gets connected |
| identifier | an identifier for this connection (this identifier can later be requested with get_identifier()) |
References log_debug2, LOGT_IO, mio_reset(), and mio_write().
destruct an instance of connected sockets, this will also close the connection if it is still present
| sigc::signal<void, connected_sockets*>& xmppd::proxy65::connected_sockets::event_closed | ( | ) | [inline] |
event that signals that the connection has been closed
a pointer to the instance that has been closed gets passed with the event
| size_t xmppd::proxy65::connected_sockets::get_forwarded_traffic | ( | ) | [inline] |
get the amount of traffic that has been forwarded already
| const std::string& xmppd::proxy65::connected_sockets::get_identifier | ( | ) | [inline] |
get the identifier for this connection
1.7.6.1