ImmutableList<T>.IImmutableList<T>.Replace(T, T, IEqualityComparer<T>) ImmutableList<T>.IImmutableList<T>.Replace(T, T, IEqualityComparer<T>) ImmutableList<T>.IImmutableList<T>.Replace(T, T, IEqualityComparer<T>) Method

Définition

Remplace un élément de la liste par l’élément spécifié.Replaces an element in the list with the specified element.

 virtual System::Collections::Immutable::IImmutableList<T> ^ System.Collections.Immutable.IImmutableList<T>.Replace(T oldValue, T newValue, System::Collections::Generic::IEqualityComparer<T> ^ equalityComparer) = System::Collections::Immutable::IImmutableList<T>::Replace;
System.Collections.Immutable.IImmutableList<T> IImmutableList<T>.Replace (T oldValue, T newValue, System.Collections.Generic.IEqualityComparer<T> equalityComparer);
Function Replace (oldValue As T, newValue As T, equalityComparer As IEqualityComparer(Of T)) As IImmutableList(Of T) Implements IImmutableList(Of T).Replace

Paramètres

oldValue
T T T

Élément à remplacer.The element to replace.

newValue
T T T

Élément avec lequel remplacer l’ancien élément.The element to replace the old element with.

equalityComparer
IEqualityComparer<T> IEqualityComparer<T> IEqualityComparer<T>

Comparateur d’égalité à utiliser dans la recherche.The equality comparer to use in the search.

Retours

Implémente

Exceptions

Levé quand l’ancienne valeur n’existe pas dans la liste.Thrown when the old value does not exist in the list.

S’applique à