LogEventDirect

Reports an event to the Secure Logging Server (SLS).

Syntax

 
 #include <logevent.h>
 BOOL LogEventDirect (
    LOGHANDLE         Handle,
    unsigned char    *Component,
    unsigned long     ID,
    unsigned long     LogLevel,
    unsigned long     GroupID,
    unsigned long     Flags,
    unsigned char    *Text1,
    unsigned char    *Text2,
    unsigned long     Value1,
    unsigned long     Value2,
    unsigned long     MIMEHint,
    unsigned long     Size,
    void             *Data);
 

Parameters

Handle
(IN) Log handle of the SLS connection to receive the event.
Component
(IN) The component of the event being reported without the AppName prefix. The AppName is automatically appended by the SLS.
ID
(IN) Unique ID for this log event.
LogLevel
(IN) Log level (such as emergency, error, or warning). Predefined levels are contained in the following table:

Flag

Description

LE_EMERGENCY

Events that cause the reporting application to shut down

LE_ALERT

Events that require immediate attention

LE_CRITICAL

Events that can cause parts of the reporting system to malfunction

LE_ERROR

Events describing errors that can be handled by the reporting system

LE_WARNING

Negative events not representing a problem

LE_NOTICE

Events (positive or negative) an administrator can use to understand or improve the use and operation of the reporting system

LE_INFO

Positive events of any importance

LE_DEBUG

Events of relevance for support or engineers to debug operation of the reporting system

GroupID
(IN) ID used to group events.
Flags
(IN) Options for logging this event. The following table contains possible values for this parameter:

Flag

Description

LE_SYNCHRONOUS

Do not return until the reported event is committed to storage by the SLS, or an error is encountered.

Text1
(IN) First string to be logged.
Text2
(IN) Second string to be logged.
Value1
(IN) First number to be logged.
Value2
(IN) Second number to be logged.
MIMEHint
(IN) MIME type of data. Predefined hints are contained in the logevent.h header file.
Size
(OUT) Size of data.
Data
(OUT) Pointer to the binary data to be logged.

Return Values

TRUE

The event was successfully transmitted to the SLS or committed to the local cache.

FALSE

The event could not be transmitted or stored. The error is retrieved by LogGetError.