ArraySegment<T>.CopyTo 方法

定義

多載

名稱 Description
CopyTo(ArraySegment<T>)

將此實例的內容複製到指定的目標陣列區段中,且該區段為同類型 T

CopyTo(T[])

將此實例的內容複製到指定且類型相同的 T目的陣列中。

CopyTo(T[], Int32)

將此實例的內容從指定的目的索引開始,複製到相同類型的 T指定目的陣列中。

CopyTo(ArraySegment<T>)

來源:
ArraySegment.cs
來源:
ArraySegment.cs
來源:
ArraySegment.cs
來源:
ArraySegment.cs
來源:
ArraySegment.cs

將此實例的內容複製到指定的目標陣列區段中,且該區段為同類型 T

public:
 void CopyTo(ArraySegment<T> destination);
public void CopyTo(ArraySegment<T> destination);
member this.CopyTo : ArraySegment<'T> -> unit
Public Sub CopyTo (destination As ArraySegment(Of T))

參數

destination
ArraySegment<T>

將此實例內容複製到的陣列區段。

例外狀況

此實例的底層陣列為 null

-或-

destination 底層陣列為 null

此實例底層陣列的長度大於底 destination層陣列的長度。

適用於

CopyTo(T[])

來源:
ArraySegment.cs
來源:
ArraySegment.cs
來源:
ArraySegment.cs
來源:
ArraySegment.cs
來源:
ArraySegment.cs

將此實例的內容複製到指定且類型相同的 T目的陣列中。

public:
 void CopyTo(cli::array <T> ^ destination);
public void CopyTo(T[] destination);
member this.CopyTo : 'T[] -> unit
Public Sub CopyTo (destination As T())

參數

destination
T[]

將此實例內容複製到的類型 T 陣列。

例外狀況

此實例的底層陣列為 null

適用於

CopyTo(T[], Int32)

來源:
ArraySegment.cs
來源:
ArraySegment.cs
來源:
ArraySegment.cs
來源:
ArraySegment.cs
來源:
ArraySegment.cs

將此實例的內容從指定的目的索引開始,複製到相同類型的 T指定目的陣列中。

public:
 virtual void CopyTo(cli::array <T> ^ destination, int destinationIndex);
public:
 void CopyTo(cli::array <T> ^ destination, int destinationIndex);
public void CopyTo(T[] destination, int destinationIndex);
abstract member CopyTo : 'T[] * int -> unit
override this.CopyTo : 'T[] * int -> unit
member this.CopyTo : 'T[] * int -> unit
Public Sub CopyTo (destination As T(), destinationIndex As Integer)

參數

destination
T[]

將此實例內容複製到的類型 T 陣列。

destinationIndex
Int32

儲存開始的索引 destination

實作

例外狀況

此實例的底層陣列為 null

適用於