IWDFIoTarget::GetTargetFile method (wudfddi.h)
Warning
UMDF 2 is the latest version of UMDF and supersedes UMDF 1. All new UMDF drivers should be written using UMDF 2. No new features are being added to UMDF 1 and there is limited support for UMDF 1 on newer versions of Windows 10. Universal Windows drivers must use UMDF 2. For more info, see Getting Started with UMDF.
The GetTargetFile method retrieves the framework file object that is associated with the I/O target object.
Syntax
void GetTargetFile(
[out] IWDFFile **ppWdfFile
);
Parameters
[out] ppWdfFile
Pointer to a buffer that receives a pointer to the IWDFFile interface for the I/O target's file object.
Return value
None
Remarks
If a framework file object is associated with an I/O target object, the framework includes the file object with I/O requests that the driver sends to the I/O target object.
When a driver formats an I/O request, an I/O target object enables the driver to use either the same file that the request started with or a new file.
The default I/O target has no file object, so a call to GetTargetFile for the default I/O target retrieves NULL.
For more information about I/O targets, see Using I/O Targets in UMDF.
Examples
For a code example of how to use the GetTargetFile method, see IWDFIoTarget::FormatRequestForWrite.
Requirements
Requirement | Value |
---|---|
End of support | Unavailable in UMDF 2.0 and later. |
Target Platform | Desktop |
Minimum UMDF version | 1.5 |
Header | wudfddi.h (include Wudfddi.h) |
DLL | WUDFx.dll |