ICorDebugType::EnumerateTypeParameters Method
Gets an interface pointer to an ICorDebugTypeEnum Interface that contains the Type parameters of the class referenced by this ICorDebugType Interface.
HRESULT EnumerateTypeParameters (
[out] ICorDebugTypeEnum **ppTyParEnum
);
Parameters
Parameter | Description |
---|---|
ppTyParEnum |
[out] A pointer to the address of an ICorDebugTypeEnum Interface that contains the parameters of the type. |
Remarks
EnumerateTypeParameters can be used if the CorElementType Enumeration value returned by ICorDebugType::GetType Method is ELEMENT_TYPE_CLASS, ELEMENT_TYPE_VALUETYPE, ELEMENT_TYPE_ARRAY, ELEMENT_TYPE_SZARRAY, ELEMENT_TYPE_BYREF, ELEMENT_TYPE_PTR, or ELEMENT_TYPE_FNPTR. The number of parameters and their order depends on the type:
ELEMENT_TYPE_CLASS or ELEMENT_TYPE_VALUETYPE: The number of type parameters contained in the ICorDebugTypeEnum Interface that this method returns, will depend on the number of formal type parameters for the corresponding class. For example, if the type is
class Dict<String,int32>
, then EnumerateTypeParameters will return an ICorDebugTypeEnum Interface that contains objects representing String and int32 in sequence.ELEMENT_TYPE_FNPTR: The number of type parameters contained in the ICorDebugTypeEnum Interface will be one greater than the number of arguments accepted by the function. The first type parameter contained in the ICorDebugTypeEnum Interface is the return type for the function, and the subsequent type parameters are the function's parameters.
ELEMENT_TYPE_ARRAY, ELEMENT_TYPE_SZARRAY, ELEMENT_TYPE_BYREF, or ELEMENT_TYPE_PTR: One type parameter will be returned. For example, if the type is an array type such as
int32[]
, then EnumerateTypeParameters will return an ICorDebugTypeEnum Interface that contains an object representing int32.
Requirements
Platforms: Windows 2000, Windows XP, Windows Server 2003 family
Header: CorDebug.idl
Library: CorGuids.lib
.NET Framework Version: 2.0