IWbemHiPerfProvider::StopRefreshing method

The IWbemHiPerfProvider::StopRefreshing method stops refreshing the object or enumerator corresponding to the supplied identifier. The WMI Refresher calls this method in response to a client request to IWbemConfiguratorRefresher::Remove. The provider should check the objects and enumerators associated with the refresher for a matching identifier. When the provider finds an identifier, the provider should remove or release the enumerator.

Note  If a provider does not implement this method, it must return WBEM_E_PROVIDER_NOT_CAPABLE. A provider should implement StopRefreshing if it implements IWbemHiPerfProvider::CreateRefreshableEnum or IWbemHiPerfProvider::CreateRefreshableObject.

Syntax


HRESULT StopRefreshing(
  [in]  IWbemRefresher *pRefresher,
  [in]  long lId,
  [in]  long lFlags
);

Parameters

pRefresher [in]

A pointer to a IWbemRefresher object that contains a refresher obtained by calling IWbemHiPerfProvider::CreateRefresher.

lId [in]

An integer containing a refresher identifier that uniquely identifies the object to stop refreshing.

lFlags [in]

An integer containing the flags.

Return value

This method returns an HRESULT indicating the status of the method call. The following table lists the value contained within an HRESULT.

Return codeDescription
WBEM_S_NO_ERROR

The method was successful.

WBEM_E_PROVIDER_NOT_CAPABLE

The provider does not support refreshing instance objects. Return this error code in all cases if a more specific code is not required.

WBEM_S_FALSE

The requested object or enumerator could not be found.

WBEM_E_NOT_FOUND

The provider could not find an object or enumerator corresponding to the supplied identifier.

WBEM_E_FAILED

The provider failed internally, even though the operation was valid.

 

Remarks

It is not necessary to call StopRefreshing to clean up a refresher. It is sufficient simply to delete the refresher; that is, to release all references to it. Deleting the refresher causes the cleanup of all objects and enumerators within it.

Requirements

Minimum supported client

Windows Vista

Minimum supported server

Windows Server 2003

Header

Wbemprov.h (include Wbemidl.h)

Library

Wbemuuid.lib

DLL

Wmiprvsd.dll

See also

IWbemHiPerfProvider
Developing a WMI Provider
Writing an Instance Provider
Making an Instance Provider into a High-Performance Provider
Performance Counter Provider

 

 

Show:
© 2014 Microsoft