LWL v0.8 - Reference Manual


extern void lwl_write_log

(lwlh_t HANDLE, lwl_priority_t PRI,
  char* FORMAT, ... )

Log a message to the file associated to a LWL handle.

Documentation

Log a message to the file associated to a LWL handle. Write the given formated message of priority PRI to the HANDLE's file. To change the HANDLE's file, you can use lwl_set_attributes() function. The message FORMAT must be used like printf(). The message will be logged only if PRI is <= HANDLE's log level (wich you can consult with lwl_get_log_level()). To change HANDLE's log level, you can use lwl_set_attributes() function.

Example:

lwl_write_log (my_handle, LWL_PRI_DEBUG, "%s:%d-%s ERROR", __FILE__, __LINE__, __FUNCTION__);

Requires: HANDLE must be a LWL handle successfully allocated by lwl_alloc().

docppcomment:

Parameters:
HANDLE - The LWL handle to use.
PRI - The priority of the message to log.
FORMAT - The message to log.
... - Variables to include into the message.
See Also:
lwl_get_log_level
lwl_set_attributes

Alphabetic index


LWL Reference Manual
Last modified: Wed Jun 26 15:51:54 CEST 2002