mirror of
https://github.com/Govor-team/Govor.git
synced 2026-07-21 11:44:56 +00:00
18 lines
726 B
C#
18 lines
726 B
C#
using Govor.ConsoleClient.Services.Implementations;
|
|
using Govor.ConsoleClient.Services.Interfaces;
|
|
using Microsoft.Extensions.DependencyInjection;
|
|
|
|
namespace Govor.ConsoleClient.Services.Extensions;
|
|
|
|
public static class ServiceCollectionExtensions
|
|
{
|
|
public static IServiceCollection AddApplicationServices(this IServiceCollection services)
|
|
{
|
|
services.AddSingleton<IInputPipeline, InputPipeline>();
|
|
services.AddSingleton<ICommandDispatcher, CommandDispatcher>();
|
|
services.AddSingleton<IMiddlewarePipeline, MiddlewarePipeline>();
|
|
services.AddSingleton<ConsoleLogger>();
|
|
services.AddSingleton<ILogger>(sp => sp.GetRequiredService<ConsoleLogger>());
|
|
return services;
|
|
}
|
|
} |