4.4 Event Retrieval
All events are retrieved using the current Standard Runtime Library (SRL) event retrieval mechanisms (see the Standard Runtime Library API Programming Guide for details), including event handlers. The gc_GetMetaEvent( ) function or, for Windows extended asynchronous models, the gc_GetMetaEventEx( ) function, maps the current SRL event into a metaevent. A metaevent is a data structure that explicitly contains the information describing the event. This data structure provides uniform information retrieval among all call control libraries.
For Global Call events, the structure contains Global Call related information (CRN and line device) used by the application. For events that are not Global Call events, the IntelŪ DialogicŪ device descriptor, the event type, the event data pointer to the variable length data and the length of the variable data are available through the METAEVENT structure. Since event data is present in the metaevent and thus will be stored in the METAEVENT structure, corresponding SRL calls to obtain event information need not be made.
The LDID associated with an event is available from the linedev field of the metaevent. The CRN associated with each event is available from the crn field of the metaevent (only if the event is related to the CRN). If the CRN is 0, then the event is not a call-related event.
Late events are events that arrive for a released CRN. Late events can occur if the gc_ReleaseCallEx( ) function is issued before the application has retrieved all of the termination events. To avoid late events, the application should issue a gc_DropCall( ) function before issuing the gc_ReleaseCallEx( ) function. Failure to issue this function could result in one or more of the following problems:
- memory problems due to memory being allocated and not being released
- blocking condition
- events sent to the previous user of a CRN could be processed by a later user of the CRN with unexpected results
The reason for an event is retrieved using the gc_ResultInfo( ) function. The information returned uniquely identifies the cause of the event.
Click here to contact Telecom Support Resources
Copyright 2002, Intel Corporation