Function silc_stream_set_notifier
SYNOPSIS
SilcBool silc_stream_set_notifier(SilcStream stream,
SilcSchedule schedule,
SilcStreamNotifier notifier,
void *context);
DESCRIPTION
Schedule `stream' for stream events. Set the `notifier' callback to
be called when some event takes place on the stream. The event will
be delievered to the `notifier' callback with the `context'. It is
called for example when data is available for reading or writing, or
if an error occurs. This can be called at any time for valid stream.
This call will also set the `stream' into non-blocking mode.
If `notifier' is set to NULL no callback will be called for the stream,
and the stream is not scheduled anymore.
This function returns FALSE if the `schedule' was provided and the
stream could not be scheduled. The actual API for `stream' may provide
access to the actual error information. Returns TRUE on success.
|