Pointer.Box(Void*, Type) 메서드

정의

제공된 관리되지 않는 메모리 포인터와 해당 포인터와 연결된 형식을 관리 Pointer 되는 래퍼 개체에 입력합니다. 호출 중에 네이티브 코드에서 액세스할 수 있도록 값과 형식이 저장됩니다.

public:
 static System::Object ^ Box(void* ptr, Type ^ type);
public static object Box(void* ptr, Type type);
[System.Security.SecurityCritical]
public static object Box(void* ptr, Type type);
static member Box : nativeptr<unit> * Type -> obj
[<System.Security.SecurityCritical>]
static member Box : nativeptr<unit> * Type -> obj

매개 변수

ptr
Void*

제공된 관리되지 않는 메모리 포인터입니다.

type
Type

매개 변수와 연결된 형식입니다 ptr .

반품

포인터 개체입니다.

특성

예외

type 가 포인터가 아닙니다.

typenull입니다.

적용 대상