Språk

ExceptionAsHResultMarshaller<T> Klass

Definition

Konverterar ett undantagsobjekt till värdet för dess HResult konverterade till T.

generic <typename T>
 where T : value classpublic ref class ExceptionAsHResultMarshaller abstract sealed
[System.Runtime.InteropServices.Marshalling.CustomMarshaller(typeof(System.Exception), System.Runtime.InteropServices.Marshalling.MarshalMode.UnmanagedToManagedOut, typeof(System.Runtime.InteropServices.Marshalling.ExceptionAsHResultMarshaller<>))]
public static class ExceptionAsHResultMarshaller<T> where T : struct
[<System.Runtime.InteropServices.Marshalling.CustomMarshaller(typeof(System.Exception), System.Runtime.InteropServices.Marshalling.MarshalMode.UnmanagedToManagedOut, typeof(System.Runtime.InteropServices.Marshalling.ExceptionAsHResultMarshaller<>))>]
type ExceptionAsHResultMarshaller<'T (requires 'T : struct)> = class
Public Class ExceptionAsHResultMarshaller(Of T)

Typparametrar

T

Den ohanterade typen som HResult konverteras till.

Arv
ExceptionAsHResultMarshaller<T>
Attribut

Kommentarer

Den här typen används av COM-källgeneratorn för att aktivera undantag för marshalling till HResult för undantaget.

Metoder

Name Description
ConvertToUnmanaged(Exception)

Konverterar ett undantagsobjekt till värdet för dess HResult konverterade till T.

Gäller för