Method Insert
Insert<T, TList>(IListEntityService<T, TList>, TList, CancellationToken)
Inserts a single entity of type TList into the IListEntityService.
public static Task<List<PrimaryKeys<T>>> Insert<T, TList>(this IListEntityService<T, TList> entityService, TList entity, CancellationToken cancellationToken = default) where T : class where TList : class
Parameters
entityServiceIListEntityService<T, TList>The IListEntityService instance.
entityTListThe entity to insert.
cancellationTokenCancellationTokenThe cancellation token.
Returns
- Task<List<PrimaryKeys<T>>>
A task representing the asynchronous operation.
Type Parameters
TThe type of the entity.
TListThe type of the entity in the list.
Insert<T, TInsert>(IInsertEntityService<T, TInsert>, TInsert, CancellationToken)
Inserts a single entity of type TInsert into the IInsertEntityService.
public static Task<List<PrimaryKeys<T>>> Insert<T, TInsert>(this IInsertEntityService<T, TInsert> entityService, TInsert entity, CancellationToken cancellationToken = default) where T : class where TInsert : class
Parameters
entityServiceIInsertEntityService<T, TInsert>The IInsertEntityService instance.
entityTInsertThe entity to insert.
cancellationTokenCancellationTokenThe cancellation token.
Returns
- Task<List<PrimaryKeys<T>>>
A task representing the asynchronous operation.
Type Parameters
TThe type of the entity.
TInsertThe type of the entity to insert.
Insert<T>(IEntityService<T>, T, CancellationToken)
Inserts a single entity of type T into the IEntityService.
public static Task<PrimaryKeys<T>> Insert<T>(this IEntityService<T> entityService, T entity, CancellationToken cancellationToken = default) where T : class
Parameters
entityServiceIEntityService<T>The IEntityService instance.
entityTThe entity to insert.
cancellationTokenCancellationTokenThe cancellation token.
Returns
- Task<PrimaryKeys<T>>
A task representing the asynchronous operation.
Type Parameters
TThe type of the entity.