Collection<T>.IList.Add(Object) 方法

定义

将项添加到 IList 中。Adds an item to the IList.

 virtual int System.Collections.IList.Add(System::Object ^ value) = System::Collections::IList::Add;
int IList.Add (object value);
Function Add (value As Object) As Integer Implements IList.Add

参数

value
Object

要添加到 ObjectIListThe Object to add to the IList.

返回

插入新元素的位置。The position into which the new element was inserted.

实现

异常

value 是一个无法赋值给 IList 的类型。value is of a type that is not assignable to the IList.

注解

此方法为 O (1)操作。This method is an O(1) operation.

适用于