संपादित करें

इसके माध्यम से साझा किया गया


SafeHandleMarshaller<T>.ManagedToUnmanagedRef Struct

Definition

Marshals a SafeHandle as its underlying handle value as a ref parameter in managed-to-unmanaged scenarios like P/Invokes.

public:  where T : SafeHandlevalue class SafeHandleMarshaller<T>::ManagedToUnmanagedRef
public struct SafeHandleMarshaller<T>.ManagedToUnmanagedRef where T : SafeHandle
type SafeHandleMarshaller<'T (requires 'T :> SafeHandle)>.ManagedToUnmanagedRef = struct
Public Structure SafeHandleMarshaller(Of T).ManagedToUnmanagedRef

Type Parameters

T
Inheritance
SafeHandleMarshaller<T>.ManagedToUnmanagedRef

Constructors

SafeHandleMarshaller<T>.ManagedToUnmanagedRef()

Initializes a new instance of SafeHandleMarshaller<T>.ManagedToUnmanagedRef in a default state.

Methods

Free()

Frees any resources and reference counts owned by the marshaller.

FromManaged(T)

Initializes the marshaller from a managed handle.

FromUnmanaged(IntPtr)

Initializes the marshaller from an unmanaged handle.

OnInvoked()

Notifies the marshaller that the native call has been invoked.

ToManagedFinally()

Retrieves the managed handle from the marshaller.

ToUnmanaged()

Retrieves the unmanaged handle.

Applies to