Skip to content

dimesoftware/services

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

15 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Logo

Services

Introduction

Contracts for the service layer of any project.

Getting Started

  • You must have Visual Studio 2022 Community or higher.
  • The dotnet cli is also highly recommended.

About this project

The most notable types in this assembly include:

  • IQueryService<T>: matches the R in CRUD operators
  • ICommandService<T>: matches the CUD in CRUD operations
  • IService<T>: Defines the capabilities of both IQueryService<T> and ICommandService<T>
  • IServiceLocator: Defines how to instantiate service class instances

Build and Test

  • Run dotnet restore
  • Run dotnet build
  • Run dotnet test

Installation

Use the package manager NuGet to install Dime.System:

dotnet add package Dime.Services

Usage

using Dime;

public class CustomerService : ICustomerService<Customer>
{
  public async Task<IEnumerable<CustomerDto>> GetAllAsync<CustomerDto>()
  {
      IEnumerable<Customer> customers = await this.Context.Customers.ToListAsync();
      return customers.Select(x => this.Mapper.Map<CustomerDto>(x));
  }
}

Contributing

PRs Welcome

Pull requests are welcome. Please check out the contribution and code of conduct guidelines.

License

License

About

๐Ÿ‘” Contracts for the service layer of any project.

Topics

Resources

License

Code of conduct

Contributing

Stars

Watchers

Forks

Packages

No packages published

Languages