AccessControlList.CopyTo(AccessControlEntry[], Int32) 方法

定义

将整个访问控制列表复制到访问控制项的兼容的一维数组,并且从目标数组的指定索引开始。Copies the entire access control list to a compatible one-dimensional array of access control entries, starting at the specified index of the target array.

public:
 void CopyTo(cli::array <System::Messaging::AccessControlEntry ^> ^ array, int index);
public void CopyTo (System.Messaging.AccessControlEntry[] array, int index);
member this.CopyTo : System.Messaging.AccessControlEntry[] * int -> unit
Public Sub CopyTo (array As AccessControlEntry(), index As Integer)

参数

array
AccessControlEntry[]

一个 AccessControlEntry 类型的数组,访问控制列表项将被复制到其中。An array of type AccessControlEntry to which the access control list entries will be copied. 该数组的索引必须从零开始。The array must have zero-based indexing.

index
Int32

数组中将从其开始复制访问控制列表项的索引。The index in the array at which to begin copying the access control list entries.

例外

array 参数为 nullThe array parameter is null.

index 参数小于零。The index parameter is less than zero.

index 参数大于或等于 array 参数的长度。The index parameter is greater than or equal to the length of the array parameter.

- 或 --or- 源访问控制列表中元素的数目大于从 index 到访问控制项的目标数组的结尾的可用空间。The number of elements in the source access control list is greater than the available space from index to the end of the destination array of access control entries.

适用于

另请参阅