ImmutableArray<T>.SetItem(Int32, T) 方法

定义

将指定索引处的项替换为指定的项。

public:
 System::Collections::Immutable::ImmutableArray<T> SetItem(int index, T item);
public System.Collections.Immutable.ImmutableArray<T> SetItem(int index, T item);
member this.SetItem : int * 'T -> System.Collections.Immutable.ImmutableArray<'T>
Public Function SetItem (index As Integer, item As T) As ImmutableArray(Of T)

参数

index
Int32

要替换的项的索引。

item
T

要添加到列表中的项。

返回

包含 item 指定索引处的新数组。

适用于