Pointer.Box(Void*, Type) Méthode
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Boxe le pointeur de mémoire non managé fourni et le type associé à ce pointeur dans un objet wrapper managé Pointer . La valeur et le type sont enregistrés afin qu’ils soient accessibles à partir du code natif lors d’un appel.
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
Paramètres
- ptr
- Void*
Pointeur de mémoire non managé fourni.
- type
- Type
Type associé au ptr paramètre.
Retours
Objet pointeur.
- Attributs
Exceptions
type n’est pas un pointeur.
type a la valeur null.