分享方式


RuntimeHelpers.AllocateTypeAssociatedMemory 方法

定義

多載

名稱 Description
AllocateTypeAssociatedMemory(Type, Int32)

設定與 type 相關聯的記憶體,並在 卸除 時 Type 釋出 。

AllocateTypeAssociatedMemory(Type, Int32, Int32)

AllocateTypeAssociatedMemory(Type, Int32)

來源:
RuntimeHelpers.CoreCLR.cs
來源:
RuntimeHelpers.CoreCLR.cs
來源:
RuntimeHelpers.CoreCLR.cs
來源:
RuntimeHelpers.CoreCLR.cs

設定與 type 相關聯的記憶體,並在 卸除 時 Type 釋出 。

public:
 static IntPtr AllocateTypeAssociatedMemory(Type ^ type, int size);
public static IntPtr AllocateTypeAssociatedMemory(Type type, int size);
static member AllocateTypeAssociatedMemory : Type * int -> nativeint
Public Shared Function AllocateTypeAssociatedMemory (type As Type, size As Integer) As IntPtr

參數

type
Type

與配置記憶體相關聯的類型。

size
Int32

要配置的記憶體數量,以位元組為單位。

傳回

IntPtr

nativeint

配置的記憶體。

適用於

AllocateTypeAssociatedMemory(Type, Int32, Int32)

public:
 static IntPtr AllocateTypeAssociatedMemory(Type ^ type, int size, int alignment);
public static IntPtr AllocateTypeAssociatedMemory(Type type, int size, int alignment);
static member AllocateTypeAssociatedMemory : Type * int * int -> nativeint
Public Shared Function AllocateTypeAssociatedMemory (type As Type, size As Integer, alignment As Integer) As IntPtr

參數

type
Type
size
Int32
alignment
Int32

傳回

IntPtr

nativeint

適用於