17 #ifndef YAMICORE_LISTENER_H_INCLUDED 18 #define YAMICORE_LISTENER_H_INCLUDED 21 #include "details-fwd.h" 24 #ifdef YAMI4_WITH_OPEN_SSL 30 #include <openssl/ssl.h> 31 #endif // YAMI4_WITH_OPEN_SSL 34 #include <details-types.h> 46 void init(allocator & alloc,
47 channel_group & group, mutex & mtx,
49 void * connection_hook_hint,
51 void * io_error_callback_hint);
57 void close_resource();
60 const char * get_target()
const {
return target_; }
61 protocol get_protocol()
const {
return protocol_; }
63 io_descriptor_type get_io_descriptor()
const {
return fd_; }
65 void set_selector_index(
int index) { selector_index_ = index; }
66 int get_selector_index()
const {
return selector_index_; }
69 bool is_qnx_receiver_ready()
const;
70 #endif // YAMI4_WITH_QNX 72 void inc_ref() { ++ref_count_; }
73 void dec_ref() { --ref_count_; }
74 bool can_be_removed()
const {
return ref_count_ == 0; }
88 #endif // YAMI4_WITH_QNX 96 #endif // YAMI4_WITH_QNX 98 #ifdef YAMI4_WITH_OPEN_SSL 101 #endif // YAMI4_WITH_OPEN_SSL 105 std::size_t ref_count_;
107 const char * target_;
111 io_descriptor_type fd_;
115 channel_group * group_;
118 char * frame_buffer_;
119 std::size_t frame_buffer_size_;
121 #ifdef YAMI4_WITH_QNX 123 msg_receiver msg_receiver_;
124 #endif // YAMI4_WITH_QNX 127 void * connection_hook_hint_;
130 void * io_error_callback_hint_;
137 #endif // YAMICORE_LISTENER_H_INCLUDED void(* io_error_function)(void *hint, int error_code, const char *description)
Type of function callback for internal I/O error logging.
Definition: core.h:149
void(* new_incoming_connection_function)(void *hint, const char *source, std::size_t index, std::size_t sequence_number)
Definition: core.h:90
Namespace devoted for everything related to YAMI4.
Definition: agent.h:25
result
General type for reporting success and error states.
Definition: core.h:32