Table of Contents

Class SetInList

Namespace
NanoByte.Common.Undo
Assembly
NanoByte.Common.dll

Factory methods for SetInList<T>.

public static class SetInList
Inheritance
object
SetInList

Methods

For<T>(IList<T>, T, T)

Creates a new set in list command.

public static SetInList<T> For<T>(IList<T> list, T oldElement, T newElement) where T : notnull

Parameters

list IList<T>

The list to be modified.

oldElement T

The old element currently in the list to be replaced.

newElement T

The new element to take the place of oldElement in the list.

Returns

SetInList<T>

Type Parameters

T

The type of elements the list contains.