// wdfdevice.h
typedef struct _WDF_FILEOBJECT_CONFIG {
ULONG Size;
PFN_WDF_DEVICE_FILE_CREATE EvtDeviceFileCreate;
PFN_WDF_FILE_CLOSE EvtFileClose;
PFN_WDF_FILE_CLEANUP EvtFileCleanup;
WDF_TRI_STATE AutoForwardCleanupClose;
WDF_FILEOBJECT_CLASS FileObjectClass;
} WDF_FILEOBJECT_CONFIG, *PWDF_FILEOBJECT_CONFIG;
View the official Windows Driver Kit DDI reference
No description available.
[Applies to KMDF and UMDF]
The WDF_FILEOBJECT_CONFIG structure contains configuration information of a driver's framework file objects.
Size
The size, in bytes, of this structure.
EvtDeviceFileCreate
A pointer to the driver's EvtDeviceFileCreate callback function, or NULL.
EvtFileClose
A pointer to the driver's EvtFileClose callback function, or NULL.
EvtFileCleanup
A pointer to the driver's EvtFileCleanup callback function, or NULL.
AutoForwardCleanupClose
A WDF_TRI_STATE-typed value. For more information about this member, see the following Comments section.
FileObjectClass
A WDF_FILEOBJECT_CLASS-typed value that identifies whether the driver requires a framework file object to represent each file that an application or another driver creates or opens. Additionally, this value specifies where the framework can store the object's handle.
The WDF_FILEOBJECT_CONFIG structure is used as input to the WdfDeviceInitSetFileObjectConfig method.
WDF_FILEOBJECT_CONFIG must be initialized by calling WDF_FILEOBJECT_CONFIG_INIT.
If AutoForwardCleanupClose is set to WdfTrue, the framework does the following:
If AutoForwardCleanupClose is set to WdfFalse, the framework does not forward file creation, cleanup, or close requests. Instead, the framework completes the requests for the driver.
If AutoForwardCleanupClose is set to WdfUseDefault, the framework uses WdfTrue behavior for filter drivers and WdfFalse behavior for function drivers.
Your driver's local I/O target must always receive an equal number of I/O requests with request types of WdfRequestTypeCreate, WdfRequestTypeCleanup, and WdfRequestTypeClose. Therefore, if the driver provides either an EvtDeviceFileCreate callback function or an I/O queue that receives file creation requests, you must use the following rules: