NMS OAM event structure

The buffer field in the CTA_EVENT structure points to an OAM_MSG structure defined in oamdef.h. The structure contains more information about the event:

typedef struct oam_msg_tag
{
    DWORD dwMsgLen;       // Message length, including appended      //
                          // name & message strings                  //
    DWORD dwCode;         // Message code                            //
    DWORD dwSeverity;     // Message severity                        //
    DWORD dwOfsSzName;    // Offset to name string of source         //
                          // managed object                          //
    DWORD dwOfsSzMessage; // Offset to text message string           //
    DWORD dwValue;        // Possible additional event-specific data //
    // (String data is appended here) //
} OAM_MSG;

The application can use the OAM_IS_OAM_EVENT macro (defined in oamdef.h) to determine if an incoming event is an NMS OAM event.

As shown in the following illustration, the OAM_MSG structure contains six DWORD fields and two strings that contain:

The OAM_MSG structure fields are described in the following table:

Field

Description

dwMsgLen

The length of the message appended to the end of the structure, including the name string and the text string.

dwCode

Event code (always equivalent to id in the CTA_EVENT structure).

dwSeverity

Severity of the message. Possible values are:

CTA_TRACE_SEVERITY_INFO - Message is informational.

CTA_TRACE_SEVERITY_WARNING - Message is a warning.

CTA_TRACE_SEVERITY_ERROR - Message is an error.

dwOfsSzName

Offset to the first byte of the name string, from beginning of OAM_MSG structure.

dwOfsSzMessage

Offset to the first byte of the text message string, from beginning of OAM_MSG structure.

dwValue

Some events place additional data here. For more information, refer to the board documentation.

(name string)

The name of the managed object associated with the message. Null-terminated.

(text message string)

Free-form text giving additional information associated with the message. Null-terminated.


The following illustration shows the relationship between CTA_EVENT and OAM_MSG, and the fields they contain: