channel

channel

Synopsis

                    TplChannelPriv;
void                call_when_ready                     (TplChannel *self,
                                                         GAsyncReadyCallback cb,
                                                         gpointer user_data);
void                call_when_ready_protected           (TplChannel *self,
                                                         GAsyncReadyCallback cb,
                                                         gpointer user_data);
TpAccount *         tpl_channel_get_account             (TplChannel *self);
void                tpl_channel_call_when_ready         (TplChannel *self,
                                                         GAsyncReadyCallback cb,
                                                         gpointer user_data);

Description

Details

TplChannelPriv

typedef struct _TplChannelPriv TplChannelPriv;


call_when_ready ()

void                call_when_ready                     (TplChannel *self,
                                                         GAsyncReadyCallback cb,
                                                         gpointer user_data);

self :

cb :

user_data :


call_when_ready_protected ()

void                call_when_ready_protected           (TplChannel *self,
                                                         GAsyncReadyCallback cb,
                                                         gpointer user_data);

This static method is called from TplChannelClass.call_when_ready, implemented by TplChannel subclasses.

See also: tpl_channel_call_when_ready()

self :

a TplChannel instance

cb :

a callback

user_data :

user's data passed to the callback

tpl_channel_get_account ()

TpAccount *         tpl_channel_get_account             (TplChannel *self);

self :

Returns :


tpl_channel_call_when_ready ()

void                tpl_channel_call_when_ready         (TplChannel *self,
                                                         GAsyncReadyCallback cb,
                                                         gpointer user_data);

The TplObserver has no idea of what TplChannel subclass intance it's dealing with. In order to prepare the subclass instance this method has to be called, which will call TplChannelClass.call_when_ready virtual method, implemented (mandatory) by TplChannel subclasses. Such method has to call, internally, TplChannelClass.call_when_ready_protected in order to prepare also the TplChannel instance.

self :

a TplChannel instance

cb :

a callback

user_data :

user's data passed to the callback