OrderedDictionary.CopyTo(Array, Int32) 方法
定义
将 OrderedDictionary 元素复制到位于指定索引处的一维 Array 对象中。Copies the OrderedDictionary elements to a one-dimensional Array object at the specified index.
public:
virtual void CopyTo(Array ^ array, int index);
public void CopyTo (Array array, int index);
abstract member CopyTo : Array * int -> unit
override this.CopyTo : Array * int -> unit
Public Sub CopyTo (array As Array, index As Integer)
参数
- array
- Array
一维 Array 对象,是从 DictionaryEntry 集合复制的 OrderedDictionary 对象的目标。The one-dimensional Array object that is the destination of the DictionaryEntry objects copied from OrderedDictionary collection. Array 必须具有从零开始的索引。The Array must have zero-based indexing.
- index
- Int32
array 中从零开始的索引,从此处开始复制。The zero-based index in array at which copying begins.
实现
注解
CopyTo方法不能保证保留集合中元素的顺序 OrderedDictionary 。The CopyTo method is not guaranteed to preserve the order of the elements in the OrderedDictionary collection.