Interface ICreateService<TModel, TContext, TQuery>
Payroll backend service with Create and Read operations
Inherited Members
Namespace: PayrollEngine.Client.Service
Assembly: PayrollEngine.Client.Core.dll
Syntax
public interface ICreateService<in TModel, in TContext, in TQuery> : IReadService<TModel, TContext, TQuery> where TContext : IServiceContext where TQuery : Query
Type Parameters
| Name | Description |
|---|---|
| TModel | |
| TContext | |
| TQuery |
Methods
CreateAsync<T>(TContext, T)
Create new object
Declaration
Task<T> CreateAsync<T>(TContext context, T obj) where T : class, TModel
Parameters
| Type | Name | Description |
|---|---|---|
| TContext | context | The service context |
| T | obj | The object |
Returns
| Type | Description |
|---|---|
| Task<T> | New created object |
Type Parameters
| Name | Description |
|---|---|
| T |
DeleteAsync(TContext, int)
Delete object
Declaration
Task DeleteAsync(TContext context, int objectId)
Parameters
| Type | Name | Description |
|---|---|---|
| TContext | context | The service context |
| int | objectId | The object id |
Returns
| Type | Description |
|---|---|
| Task |