ComInterfaceMarshaller<T> Класс

Определение

Важно!

Этот API несовместим с CLS.

Маршалирует com-интерфейс с помощью экземпляра StrategyBasedComWrappers .

generic <typename T>
public ref class ComInterfaceMarshaller abstract sealed
[System.CLSCompliant(false)]
[System.Runtime.InteropServices.Marshalling.CustomMarshaller(typeof(System.Runtime.InteropServices.Marshalling.CustomMarshallerAttribute+GenericPlaceholder), System.Runtime.InteropServices.Marshalling.MarshalMode.Default, typeof(System.Runtime.InteropServices.Marshalling.ComInterfaceMarshaller<>))]
[System.Runtime.Versioning.UnsupportedOSPlatform("android")]
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
[System.Runtime.Versioning.UnsupportedOSPlatform("ios")]
[System.Runtime.Versioning.UnsupportedOSPlatform("tvos")]
public static class ComInterfaceMarshaller<T>
[<System.CLSCompliant(false)>]
[<System.Runtime.InteropServices.Marshalling.CustomMarshaller(typeof(System.Runtime.InteropServices.Marshalling.CustomMarshallerAttribute+GenericPlaceholder), System.Runtime.InteropServices.Marshalling.MarshalMode.Default, typeof(System.Runtime.InteropServices.Marshalling.ComInterfaceMarshaller<>))>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("android")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("browser")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("ios")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("tvos")>]
type ComInterfaceMarshaller<'T> = class
Public Class ComInterfaceMarshaller(Of T)

Параметры типа

T

Управляемый тип, представляющий тип COM-интерфейса

Наследование
ComInterfaceMarshaller<T>
Атрибуты

Комментарии

Этот маршалер всегда передает Unwrap флаг GetOrCreateObjectForComInstance(IntPtr, CreateObjectFlags).

Методы

Имя Описание
ConvertToManaged(Void*)

Преобразует указатель интерфейса COM в управляемый объект.

ConvertToUnmanaged(T)

Преобразует управляемый объект в указатель com-интерфейса для COM-интерфейса, представленного T.

Free(Void*)

Освобождает ссылку на указатель интерфейса COM.

Применяется к