Method Create
Create<T>(IEntityService<T>, IPropertyValues, CancellationToken)
Creates a new entity of type T
using the IEntityService<T> and sets its property values.
public static Task<T> Create<T>(this IEntityService<T> entityService, IPropertyValues propertyValues, CancellationToken cancellationToken = default) where T : class
Parameters
entityService
IEntityService<T>The IEntityService<T> instance.
propertyValues
IPropertyValuesThe property values to set on the new entity.
cancellationToken
CancellationTokenThe cancellation token.
Returns
- Task<T>
A task representing the asynchronous operation. The task result contains the newly created entity with the specified property values set.
Type Parameters
T
The type of the entity.