SafeBuffer.ReadArray<T>(UInt64, T[], Int32, Int32) 方法

定义

重要

此 API 不符合 CLS。

从从偏移量开始的内存中读取指定的值类型数,并将其写入从索引开始的数组中。

public:
generic <typename T>
 where T : value class void ReadArray(System::UInt64 byteOffset, cli::array <T> ^ array, int index, int count);
[System.CLSCompliant(false)]
public void ReadArray<T>(ulong byteOffset, T[] array, int index, int count) where T : struct;
[<System.CLSCompliant(false)>]
member this.ReadArray : uint64 * 'T[] * int * int -> unit (requires 'T : struct)
Public Sub ReadArray(Of T As Structure) (byteOffset As ULong, array As T(), index As Integer, count As Integer)

类型参数

T

要读取的值类型。

参数

byteOffset
UInt64

从中开始读取的位置。

array
T[]

要写入的输出数组。

index
Int32

要开始写入的输出数组中的位置。

count
Int32

要从输入数组读取的值类型数,以及要写入输出数组的值类型。

属性

例外

index 小于零。

-或-

count 小于零。

arraynull

数组的长度减去索引小于 count

Initialize尚未调用该方法。

适用于

另请参阅