[]
        
(Showing Draft Content)

C1.DataCollection.IDataCollectionEx.InsertRangeAsync

InsertRangeAsync Method

InsertRangeAsync<T>(IDataCollection<T>, int, IEnumerable<T>, CancellationToken)

Inserts the specified item at the specified index in the collection.

Declaration
public static Task<int> InsertRangeAsync<T>(this IDataCollection<T> dataCollection, int index, IEnumerable<T> items, CancellationToken cancellationToken = default) where T : class?
Public Shared Function InsertRangeAsync(Of T As Class)(dataCollection As IDataCollection(Of T), index As Integer, items As IEnumerable(Of T), Optional cancellationToken As CancellationToken = Nothing) As Task(Of Integer)
Parameters
Type Name Description
IDataCollection<T> dataCollection

The data collection.

int index

The index where the item will be inserted.

IEnumerable<T> items

The items to be inserted.

CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
Task<int>
Type Parameters
Name Description
T