IImmutableList<T>.RemoveRange 方法
定义
重载
| RemoveRange(IEnumerable<T>, IEqualityComparer<T>) |
从列表中移除指定的对象。Removes the specified object from the list. |
| RemoveRange(Int32, Int32) |
从 IImmutableList<T> 中移除一系列元素。Removes a range of elements from the IImmutableList<T>. |
RemoveRange(IEnumerable<T>, IEqualityComparer<T>)
从列表中移除指定的对象。Removes the specified object from the list.
public:
System::Collections::Immutable::IImmutableList<T> ^ RemoveRange(System::Collections::Generic::IEnumerable<T> ^ items, System::Collections::Generic::IEqualityComparer<T> ^ equalityComparer);
public System.Collections.Immutable.IImmutableList<T> RemoveRange (System.Collections.Generic.IEnumerable<T> items, System.Collections.Generic.IEqualityComparer<T> equalityComparer);
public System.Collections.Immutable.IImmutableList<T> RemoveRange (System.Collections.Generic.IEnumerable<T> items, System.Collections.Generic.IEqualityComparer<T>? equalityComparer);
abstract member RemoveRange : seq<'T> * System.Collections.Generic.IEqualityComparer<'T> -> System.Collections.Immutable.IImmutableList<'T>
Public Function RemoveRange (items As IEnumerable(Of T), equalityComparer As IEqualityComparer(Of T)) As IImmutableList(Of T)
参数
- items
- IEnumerable<T>
要从列表中移除的对象。The objects to remove from the list.
- equalityComparer
- IEqualityComparer<T>
用于确定 items 是否与列表中的任何对象相匹配的相等性比较器。The equality comparer to use to determine if items match any objects in the list.
返回
如果 items 与列表中的对象匹配,则返回已移除指定对象的新不可变列表。A new immutable list with the specified objects removed, if items matched objects in the list.
适用于
RemoveRange(Int32, Int32)
从 IImmutableList<T> 中移除一系列元素。Removes a range of elements from the IImmutableList<T>.
public:
System::Collections::Immutable::IImmutableList<T> ^ RemoveRange(int index, int count);
public System.Collections.Immutable.IImmutableList<T> RemoveRange (int index, int count);
abstract member RemoveRange : int * int -> System.Collections.Immutable.IImmutableList<'T>
Public Function RemoveRange (index As Integer, count As Integer) As IImmutableList(Of T)
参数
- index
- Int32
要移除的元素范围的从零开始的起始索引。The zero-based starting index of the range of elements to remove.
- count
- Int32
要移除的元素数。The number of elements to remove.
返回
已移除元素的新不可变列表。A new immutable list with the elements removed.