Provider::ValidateFlags method

[The Provider class is part of the WMI Provider Framework which is now considered in final state, and no further development, enhancements, or updates will be available for non-security related issues affecting these libraries. The MI APIs should be used for all new development.]

The ValidateFlags method determines whether a set of flags is valid.

Syntax

HRESULT ValidateFlags(
  long     lFlags,
  FlagDefs lAcceptableFlags
);

Parameters

lFlags

Bitmask of flags that are validated.

lAcceptableFlags

Bitmask of IFlags values that are acceptable to the calling method. For more information, see Remarks.

Return Value

Returns WBEM_S_NO_ERROR if the flags are valid and WBEM_E_UNSUPPORTED_PARAMETER if one or more flags are not valid.

Remarks

This helper method can be called by an override of any of the following virtual methods to indicate which flags are acceptable as arguments to the virtual method:

The values for IAcceptableFlags are limited to the FlagDefs enumeration defined as the following:
C++
    enum FlagDefs
    {
        EnumerationFlags = 0,
        GetObjFlags = 0,
        MethodFlags = 0,
        DeletionFlags = 0,
        PutInstanceFlags = (WBEM_FLAG_CREATE_OR_UPDATE |
                            WBEM_FLAG_CREATE_ONLY |
                            WBEM_FLAG_UPDATE_ONLY),
        QueryFlags = 0
    };

Requirements

   
Windows version Windows Vista Windows Server 2008
Target Platform Windows
Header provider.h (include FwCommon.h)
Library FrameDyn.lib
DLL FrameDynOS.dll; FrameDyn.dll