Post­Sharp Documentation / API Reference / Post­Sharp.​Patterns.​Collections Namespace / Advisable­Collection(T) Class / Advisable­Collection(T) Methods / Advisable­Collection(T).​Insert Method

AdvisableCollection<T>.Insert Method

Inserts an item to the IList<T> at the specified index.

Namespace:  PostSharp.Patterns.Collections
Assembly:  PostSharp.Patterns.Common (in PostSharp.Patterns.Common.dll) Version: 6.0.18.0 (6.0.18.0)
Syntax
C#
public void Insert(
	int index,
	T item
)

Parameters

index
Type: System.Int32
The zero-based index at which item should be inserted.
item
Type: T
The object to insert into the IList<T>.

Implements

IList<T>.Insert(Int32, T)
Exceptions
ExceptionCondition
ArgumentOutOfRangeExceptionindex is not a valid index in the IList<T>.
NotSupportedExceptionThe IList<T> is read-only.
See Also