Vtk_LogOptions
Toolkit Reference

prevnext

Vtk_LogOptions

typedef struct {
enum Vtk_CtxtLogType logLevel;
Vtk_uint32 int logMode;
Vtk_Buffer logFileName;
Vtk_OpenLogCallback openLogCB;
Vtl_CloseLogCallback closeLogCB;
Vtk_WriteLogCallback writeLogCB;
}Vtk_LogOptions;

Description

This structure defines the logging options. The parameters are set by the arguments of the function Vtk_OpenLog() in the Toolkit context.

Parameters
logLevel An enumerated type, used here to specify the logging message level. Specifying a log level will also include all logging levels listed below it in the enumerated type Vtk_CtxtLogType definition. For example specify the log level of LOG_Debug to include debugging, info and error log messages. Specify log level of LOG_VaData to include all log messages.
logMode Specifies the mode of logging. Modes can be combined using the bitwise OR (|) operator. The modes are: VTK_LOG_MODE_DEFAULT--New logs are appended to old log file, no flushing. VTK_LOG_MODE_OVERWRITE--New log messages overwrite any old data. VTK_LOG_MODE_FLUSH--Each message is flushed to the log file.
logFileName The name and path of the Log File. If an empty buffer is passed, the default (vc_toolkit.log) is used.
openLogCB A pointer to a user defined callback function that opens and initializes the log stream. If NULL is passed, the default toolkit function is used.
closeLogCB A pointer to a user defined callback function that closes logging. If NULL is passed, the default toolkit function is used.
writeLogCB A pointer to a user defined callback function that writes logging messages. If NULL is passed, the default toolkit function is used.

The callback pointers are used to indicate user-defined callback functions. Use these to customize Toolkit logging, for example to log to an application specific log facility.

Either provide all three logging callback functions or none.

Notes

See Also

Data Structures

Vtk_OpenLogCallback

Vtk_WriteLogCallback

Vtk_CloseLogCallback

Vtk_OpenLog

prevnext


ValiCert, Inc.
http://www.valicert.com
Voice: +1.650.567.5469
Fax: (+1.650.254.2148
support@valicert.com