RetrieveDevicePropertyStore method

IWDFDeviceInitialize::RetrieveDevicePropertyStore 方法

The RetrieveDevicePropertyStore method retrieves a device property store that clients can read and write device properties through.

语法

HRESULT RetrieveDevicePropertyStore(
  [in, optional]   PCWSTR pcwszServiceName,
  [in]             WDF_PROPERTY_STORE_RETRIEVE_FLAGS Flags,
  [out]            IWDFNamedPropertyStore **ppPropStore,
  [out, optional]  WDF_PROPERTY_STORE_DISPOSITION *pDisposition
);

参数

pcwszServiceName [in, optional]

A pointer to a NULL-terminated string that represents the name of the device property store. This parameter is optional. The driver can pass NULL if the driver does not supply a name for a device property store.

Flags [in]

A WDF_PROPERTY_STORE_RETRIEVE_FLAGS-typed value that identifies how to retrieve the device property store.

ppPropStore [out]

A pointer to a buffer that receives a pointer to the IWDFNamedPropertyStore interface that is used to retrieve device properties.

pDisposition [out, optional]

A pointer to a variable that receives a WDF_PROPERTY_STORE_DISPOSITION-typed value that identifies whether the framework created the device property store or the device property store already existed. This parameter is optional. The driver can pass NULL if the driver does not require the disposition information.

返回值

RetrieveDevicePropertyStore returns S_OK if the operation succeeds. Otherwise, this method returns one of the error codes that are defined in Winerror.h.

评论

The caller should call the Release method of the IWDFNamedPropertyStore interface after finishing with the property store.

要求

标头

Wudfddi.h (包括Wudfddi.h)

另请参见

IWDFNamedPropertyStore
WDF_PROPERTY_STORE_DISPOSITION
WDF_PROPERTY_STORE_RETRIEVE_FLAGS

 

 

社区附加资源

添加
显示:
© 2016 Microsoft