RuntimeEnvironment.GetRuntimeInterfaceAsIntPtr(Guid, Guid) Methode
Definitie
Belangrijk
Bepaalde informatie heeft betrekking op een voorlopige productversie die aanzienlijk kan worden gewijzigd voordat deze wordt uitgebracht. Microsoft biedt geen enkele expliciete of impliciete garanties met betrekking tot de informatie die hier wordt verstrekt.
Let op
RuntimeEnvironment members SystemConfigurationFile, GetRuntimeInterfaceAsIntPtr, and GetRuntimeInterfaceAsObject are not supported and throw PlatformNotSupportedException.
Retourneert de opgegeven interface voor de opgegeven klasse.
public:
static IntPtr GetRuntimeInterfaceAsIntPtr(Guid clsid, Guid riid);
[System.Obsolete("RuntimeEnvironment members SystemConfigurationFile, GetRuntimeInterfaceAsIntPtr, and GetRuntimeInterfaceAsObject are not supported and throw PlatformNotSupportedException.", DiagnosticId="SYSLIB0019", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public static IntPtr GetRuntimeInterfaceAsIntPtr(Guid clsid, Guid riid);
public static IntPtr GetRuntimeInterfaceAsIntPtr(Guid clsid, Guid riid);
[System.Runtime.InteropServices.ComVisible(false)]
[System.Security.SecurityCritical]
public static IntPtr GetRuntimeInterfaceAsIntPtr(Guid clsid, Guid riid);
[<System.Obsolete("RuntimeEnvironment members SystemConfigurationFile, GetRuntimeInterfaceAsIntPtr, and GetRuntimeInterfaceAsObject are not supported and throw PlatformNotSupportedException.", DiagnosticId="SYSLIB0019", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
static member GetRuntimeInterfaceAsIntPtr : Guid * Guid -> nativeint
static member GetRuntimeInterfaceAsIntPtr : Guid * Guid -> nativeint
[<System.Runtime.InteropServices.ComVisible(false)>]
[<System.Security.SecurityCritical>]
static member GetRuntimeInterfaceAsIntPtr : Guid * Guid -> nativeint
Public Shared Function GetRuntimeInterfaceAsIntPtr (clsid As Guid, riid As Guid) As IntPtr
Parameters
- clsid
- Guid
De id voor de gewenste klasse.
- riid
- Guid
De id voor de gewenste interface.
Retouren
nativeint
Een onbeheerde aanwijzer naar de aangevraagde interface.
- Kenmerken
Uitzonderingen
.NET Core en .NET 5+ alleen: in alle gevallen.
Opmerkingen
In de volgende tabel ziet u de ondersteunde combinaties voor clsid en riid.
clsid |
riid |
|---|---|
| CLSID_CorMetaDataDispenser | IID_IMetaDataDispenser, IID_IMetaDataDispenserEx |
| CLSID_CorMetaDataDispenserRuntime | IID_IMetaDataDispenser, IID_IMetaDataDispenserEx |
| CLSID_CorRuntimeHost | IID_CorRuntimeHost |
| CLSID_CLRRuntimeHost | IID_CLRRuntimeHost (niet geldig voor de algemene taalruntime die wordt geleverd door het .NET Framework 4), IID_CLRRuntimeHost3 |
| CLSID_TypeNameFactory | IID_TypeNameFactory |
| CLSID_CLRStrongName | IID_CLRStrongName |
GetRuntimeInterfaceAsIntPtr is vergelijkbaar met de GetRuntimeInterfaceAsObject methode.