IWbemConfigureRefresher::AddRefresher method

The IWbemConfigureRefresher::AddRefresher method adds a refresher to a refresher. The newly added refresher is called a "child refresher" or "nested refresher". You can use this method to create a single refresher containing more than one refresher that can be updated using a single call to the Refresh method.

Syntax


HRESULT AddRefresher(
  [in]  IWbemRefresher *pRefresher,
        long           lFlags,
  [out] long           *plId
);

Parameters

pRefresher [in]

Pointer to a IWbemRefresher object to nest in this refresher.

lFlags

Reserved. This parameter must be 0 (zero).

plId [out]

Pointer to an integer returned by the provider that uniquely identifies the refreshable object.

Return value

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

WBEM_E_INVALID_PARAMETER

A parameter was not valid.

WBEM_S_NO_ERROR

The method call was successful.

WBEM_E_REFRESHER_BUSY

The refresher is busy with another operation.

Remarks

Users should not add recursively nested refreshers. The returned identifier can be used by the Remove function to remove the refresher. Although it is not necessary for the client to explicitly remove added refreshers, the client must call Release on the refreshers when they are no longer required.

Requirements

Minimum supported client

Windows Vista

Minimum supported server

Windows Server 2008

Header

Wbemcli.h (include Wbemidl.h)

Library

Wbemuuid.lib

See also

IWbemConfigureRefresher
Accessing Performance Data in C++
Making an Instance Provider into a High-Performance Provider
Performance Counter Provider

 

 

Show: