IWDFIoRequest::GetCompletionParams method

The GetCompletionParams method retrieves the parameters object for the completion of an I/O request object.

Syntax


void GetCompletionParams(
  [out] IWDFRequestCompletionParams **ppCompletionParams
);

Parameters

ppCompletionParams [out]

A pointer to a variable that receives a pointer to the IWDFRequestCompletionParams interface.

Return value

None

Examples

The following code example sends an I/O request synchronously to an I/O target. After the IWDFIoRequest::Send method returns, the example obtains the I/O request's completion status.


HRESULT hr = S_OK; 
IWDFIoRequest *pWdfRequest = NULL; 
IWDFRequestCompletionParams * FxComplParams = NULL;

//Create a request object.
hr = m_FxDevice->CreateRequest(NULL,  NULL, &pWdfRequest); 

// 
//Format request before sending.
// 
...
// 
//Send the request to an I/O target.
// 
hr = pWdfRequest->Send(pTargetDevice,
                       WDF_REQUEST_SEND_OPTION_SYNCHRONOUS,
                       0); 
if (SUCCEEDED(hr))
{
    // 
    //Get IWDFRequestCompletionParams interface and then get completion status.
    // 
    pWdfRequest->GetCompletionParams(&FxComplParams);
    hr = FxComplParams->GetCompletionStatus();
}

Requirements

Target platform

Desktop

End of support

Unavailable in UMDF 2.0 and later.

Minimum UMDF version

1.5

Header

Wudfddi.h (include Wudfddi.h)

DLL

WUDFx.dll

See also

IWDFIoRequest
IWDFIoRequest::Send
IWDFRequestCompletionParams

 

 

Send comments about this topic to Microsoft

Show:
© 2015 Microsoft