#include <communicate.h>
Public Member Functions | |
communicate () | |
~communicate () | |
Free session data. | |
void | set_dir (std::string dir) |
channel * | reading (const std::string file, sigc::signal< void, channel * > handler) |
Read a new data file. | |
channel * | writing (const std::string file) |
Write to a file. | |
channel * | client (const std::string host, int port, sigc::signal< void, channel * > handler) |
Read data from a specified connection. | |
bool | reconnect (channel *ch) |
Reconnect a client. | |
void | server (int port, sigc::signal< void, channel * > handler) |
Listen to this specific socket for requests. | |
channel * | tls_client (const std::string host, int port, sigc::signal< void, channel * > handler) |
Connect to a tls connection. | |
void | tls_server (int port, sigc::signal< void, channel * > handler) |
Listen with a tls sever for tls clients to connect. | |
void | tls_reload () |
Read the dhfile and rsafile into the tls structures. | |
void | poll () |
read and write data, including cleanup after closed connections or timeouts | |
void | complete (int timeout) |
open communication till the connection is closed or the timeout is reached | |
void | server_close () |
Indicate a shutdown of the server. | |
Public Attributes | |
std::string | user |
user id for connection | |
std::string | session |
Session id. | |
long | sessnr |
Session nr. |
communicate::communicate | ( | ) |
communicate::~communicate | ( | ) |
Free session data.
void communicate::set_dir | ( | std::string | dir | ) |
Read a new data file.
channel * communicate::writing | ( | const std::string | file | ) |
Write to a file.
bool communicate::reconnect | ( | channel * | ch | ) |
void communicate::server | ( | int | port, | |
sigc::signal< void, channel * > | handler | |||
) |
Listen to this specific socket for requests.
void communicate::tls_server | ( | int | port, | |
sigc::signal< void, channel * > | handler | |||
) |
Listen with a tls sever for tls clients to connect.
void communicate::tls_reload | ( | ) |
Read the dhfile and rsafile into the tls structures.
void communicate::poll | ( | void | ) |
read and write data, including cleanup after closed connections or timeouts
void communicate::complete | ( | int | timeout | ) |
open communication till the connection is closed or the timeout is reached
void communicate::server_close | ( | void | ) |
Indicate a shutdown of the server.
std::string communicate::user |
user id for connection
std::string communicate::session |
Session id.
long communicate::sessnr |
Session nr.