August 2003
Intermediate to advanced
928 pages
32h 1m
English
Pointer
This class allows access to
direct
pointers to .NET objects through two static
methods. Unbox( ) returns a
void* pointer to the passed object and pins it,
not allowing the garbage collector to move its place in memory, and
Box( ) returns control over the object to the .NET
runtime.
public sealed class Pointer : System.Runtime.Serialization.ISerializable { // Public Static Methods public static object Box(void*ptr, Typetype); public static void* Unbox(objectptr); }