Conceptually, this is the delivery mechanism that is probably most appropriate for datagram delivery such as UDP/IP.
To receive data from an endpoint via callback you need to:
void
function_or_method_name
(conexus::Data)void
function_or_method_name
(conexus::CData)void
and the first parameter must be either conexus::Data or conexus::CDatasigc::bind
, which is discussed in the Gtkmm tutorial and the sigc++ documentation.sigc::mem_fun
and sigc::ptr_fun
will sufficesigc::slot<void
, conexus::Data>
sigc::slot<void
, conexus::CData>
connect_to_data()
method if your function or method accepts conexus::Data as its first parameter or the connect_to_const_data()
method if your function or method accepts conexus::CData as the first parameter.The following image illustrates the sequence of operations in receiving data via callbacks.
Sequence of operations required to receive data via a callback mechanism.