aboutsummaryrefslogtreecommitdiff
path: root/src/DevHive.Web/Configurations/Extensions/ConfigureDependencyInjection.cs
blob: f93f801b52b909757bf85d5a6fb237d2522462ab (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
using DevHive.Data.Interfaces.Repositories;
using DevHive.Data.Models;
using DevHive.Data.Repositories;
using DevHive.Services.Interfaces;
using DevHive.Services.Services;
using Microsoft.Extensions.DependencyInjection;

namespace DevHive.Web.Configurations.Extensions
{
	public static class ConfigureDependencyInjection
	{
		public static void DependencyInjectionConfiguration(this IServiceCollection services)
		{
			services.AddTransient<ILanguageRepository, LanguageRepository>();
			services.AddTransient<IRoleRepository, RoleRepository>();
			services.AddTransient<ITechnologyRepository, TechnologyRepository>();
			services.AddTransient<IUserRepository, UserRepository>();
			services.AddTransient<IPostRepository, PostRepository>();

			services.AddTransient<ILanguageService, LanguageService>();
			services.AddTransient<IRoleService, RoleService>();
			services.AddTransient<ITechnologyService, TechnologyService>();
			services.AddTransient<IUserService, UserService>();
			services.AddTransient<IPostService, PostService>();
		}
	}
}