MetadataBuilder.AddInterfaceImplementation Metoda

Definicja

Dodaje implementację interfejsu do typu.

public:
 System::Reflection::Metadata::InterfaceImplementationHandle AddInterfaceImplementation(System::Reflection::Metadata::TypeDefinitionHandle type, System::Reflection::Metadata::EntityHandle implementedInterface);
public System.Reflection.Metadata.InterfaceImplementationHandle AddInterfaceImplementation (System.Reflection.Metadata.TypeDefinitionHandle type, System.Reflection.Metadata.EntityHandle implementedInterface);
member this.AddInterfaceImplementation : System.Reflection.Metadata.TypeDefinitionHandle * System.Reflection.Metadata.EntityHandle -> System.Reflection.Metadata.InterfaceImplementationHandle
Public Function AddInterfaceImplementation (type As TypeDefinitionHandle, implementedInterface As EntityHandle) As InterfaceImplementationHandle

Parametry

type
TypeDefinitionHandle

Typ implementowania interfejsu.

implementedInterface
EntityHandle

Zaimplementowany interfejs może być jednym z następujących elementów: TypeDefinitionHandle, lub TypeReferenceHandleTypeSpecificationHandle.

Zwraca

Dojście do dodanej implementacji interfejsu.

Wyjątki

implementedInterface nie ma oczekiwanego rodzaju uchwytu.

Uwagi

Implementacje interfejsu należy dodać w tej samej kolejności co odpowiednie definicje typów implementowania interfejsu.

Jeśli typ implementuje wiele interfejsów, odpowiednie wpisy muszą zostać dodane w kolejności określonej przez zakodowane indeksy (CodedIndex.TypeDefOrRefOrSpec(EntityHandle)).

Dotyczy