Platform SDK: TAPI

LINE_PROXYREQUEST

The TAPI LINE_PROXYREQUEST message delivers a request to a registered proxy function handler.

LINE_PROXYREQUEST
hDevice = (DWORD) hLine;
dwCallbackInstance = (DWORD) dwInstanceData;
dwParam1 = (DWORD) lpProxyRequest;
dwParam2 = (DWORD) 0;
dwParam3 = (DWORD) 0;

Parameters

hDevice
The application's handle to the line device on which the agent status has changed.
dwCallbackInstance
The callback instance supplied when opening the call's line.
dwParam1
Pointer to a LINEPROXYREQUEST structure containing the request to be processed by the proxy handler application.
dwParam2
Reserved.
dwParam3
Reserved.

Return Values

No return value.

Remarks

The LINE_PROXYREQUEST message is sent only to the first application that registered to handle proxy requests of the type being delivered.

The application should process the request contained in the proxy buffer and call lineProxyResponse to return data or deliver results. Processing of the request should be done within the context of the application's TAPI callback function only if it can be performed immediately, without waiting for response from any other entity. If the application needs to communicate with other entities (for example, a service provider to handle PBX-based ACD, or any other system service which might result in blocking), then the request should be queued within the application and the callback function exited to avoid delaying the receipt of further TAPI messages by the application.

At the time the LINE_PROXYREQUEST is delivered to the proxy handler, TAPI has already returned a positive dwRequestID function result to the original application and unblocked the calling thread to continue execution. The application is awaiting a LINE_REPLY message, which is automatically generated when the proxy handler application calls lineProxyResponse.

The application shall not free the memory pointed to by lpProxyRequest. TAPI frees the memory during the execution of lineProxyResponse. The application can call lineProxyResponse exactly once for each LINE_PROXYREQUEST message.

If the application receives a LINE_CLOSE message while it has pending proxy requests, it should call lineProxyResponse for each pending request, passing in an appropriate dwResult value (such as LINEERR_OPERATIONFAILED).

Requirements

  Windows NT/2000: Requires Windows NT 4.0 SP3 or later.
  Windows 95/98: Requires Windows 95 or later.
  Version: Requires TAPI 2.0 or later.
  Header: Declared in Tapi.h.

See Also

LINE_CLOSE, LINE_REPLY, LINEPROXYREQUEST, lineProxyResponse