Array.GetLongLength(Int32) 方法

定義

得到一個 64 位元整數,代表指定維度 Array內元素的數量。

public:
 long GetLongLength(int dimension);
public long GetLongLength(int dimension);
[System.Runtime.InteropServices.ComVisible(false)]
public long GetLongLength(int dimension);
member this.GetLongLength : int -> int64
[<System.Runtime.InteropServices.ComVisible(false)>]
member this.GetLongLength : int -> int64
Public Function GetLongLength (dimension As Integer) As Long

參數

dimension
Int32

需要確定其長度的零基維 Array 度。

傳回

一個 64 位元整數,代表指定維度內元素的數量。

屬性

例外狀況

dimension 小於零。

-或-

dimension 等於或大於 Rank

備註

GetLongLength 一個例子是 GetLongLength(0),它回傳了第一維 Array元素的數量。

此方法是 O(1) 作業。

適用於

另請參閱