IMetaDataImport2::EnumMethodSpecs Method

Gets an enumerator for an array of MethodSpec tokens associated with the specified MethodDef or MemberRef token.

HRESULT EnumMethodSpecs (
    [in, out] HCORENUM      *phEnum, 
    [in]      mdToken       tk,
    [out]     mdMethodSpec  rMethodSpecs[],
    [in]      ULONG         cMax,
    [out]     ULONG         *pcMethodSpecs
); 

Parameters

  • phEnum
    [in, out] A pointer to the enumerator for rMethodSpecs.

  • tk
    [in] The MemberRef or MethodDef token that represents the method whose MethodSpec tokens are to be enumerated. If the value of tk is 0 (zero), all MethodSpec tokens in the scope will be enumerated.

  • rMethodSpecs
    [out] The array of MethodSpec tokens to enumerate.

  • cMax
    [in] The requested maximum number of tokens to place in rMethodSpecs.

  • pcMethodSpecs
    [out] The returned number of tokens placed in rMethodSpecs.

Return Value

HRESULT

Description

S_OK

EnumMethodSpecs returned successfully.

S_FALSE

phEnum has no member elements. In this case, pcMethodSpecs is set to 0 (zero).

Requirements

Platforms: See .NET Framework System Requirements.

Header: Cor.h

Library: Used as a resource in MsCorEE.dll

.NET Framework Versions: 3.5 SP1, 3.5, 3.0 SP1, 3.0, 2.0 SP1, 2.0

See Also

Reference

IMetaDataImport2 Interface

IMetaDataImport Interface