Structure SilcProtocol
NAME
typedef struct SilcProtocolStruct { ... } *SilcProtocol;
DESCRIPTION
The actual protocol object. This is allocated by the silc_protocol_alloc
and holds the information about the current protocol. Information
such as the current state, execution callback and final callback.
The context is freed by silc_protocol_free function.
Short description of the field following:
SilcProtocolObject *protocol
This is the pointer to the SilcProtocolObject and holds the
protocol specific information.
SilcProtocolState state
Protocol state. The state of the protocol can be changed in the
callback function.
void *context
Context to be sent for the callback function. This is usually
object for either SILC client or server. However, this abstraction
makes it possible that this pointer could be some other object as
well. Note that the context is not delivered in any callback
function. Application can access it through this context.
SilcProtocolFinalCallback final_callback;
This is a callback function that is called with timeout _after_ the
protocol has finished or error occurs. If this is NULL, naturally
nothing will be executed. Protocol should call this function only at
SILC_PROTOCOL_STATE_END and SILC_PROTOCOL_STATE_ERROR states.
|