IMetaDataImport::GetInterfaceImplProps — Metoda
Pobiera wskaźnik do tokenów metadanych, Type które implementują określoną metodę, oraz dla interfejsu, który deklaruje tę metodę.
Składnia
HRESULT GetInterfaceImplProps (
[in] mdInterfaceImpl iiImpl,
[out] mdTypeDef *pClass,
[out] mdToken *ptkIface
);
Parametry
iiImpl
[w] Token metadanych reprezentujący metodę zwracania tokenów klasy i interfejsu.
pClass
[out] Token metadanych reprezentujący klasę, która implementuje metodę.
ptkIface
[out] Token metadanych reprezentujący interfejs definiujący zaimplementowaną metodę.
Uwagi
Wartość jest iImpl
uzyskiwana przez wywołanie metody EnumInterfaceImpls .
Załóżmy na przykład, że klasa ma mdTypeDef
wartość tokenu 0x02000007 i że implementuje trzy interfejsy, których typy mają tokeny:
- 0x02000003 (TypeDef)
- 0x0100000A (TypeRef)
- 0x0200001C (TypeDef)
Koncepcyjnie te informacje są przechowywane w tabeli implementacji interfejsu jako:
Numer wiersza | Token klasy | Token interfejsu |
---|---|---|
4 | ||
5 | 02000007 | 02000003 |
6 | 02000007 | 0100000A |
7 | ||
8 | 02000007 | 0200001C |
Jak pamiętasz, token jest wartością 4 bajtów:
- Dolne 3 bajty przechowują numer wiersza lub identyfikator RID.
- Górny bajt zawiera typ tokenu — 0x09 dla elementu
mdtInterfaceImpl
.
GetInterfaceImplProps
zwraca informacje przechowywane w wierszu, którego token jest podany w argumencie iImpl
.
Wymagania
Platformy: Zobacz Wymagania systemowe.
Nagłówka: Cor.h
Biblioteki: Uwzględnione jako zasób w MsCorEE.dll
wersje .NET Framework: dostępne od wersji 1.0