24 lines
849 B
C#
24 lines
849 B
C#
using Autofac;
|
|
using e_suite.Database.Core;
|
|
using e_suite.Database.SqlServer;
|
|
using e_suite.DependencyInjection;
|
|
|
|
namespace e_suite.Database.MigrationBuilder.DependencyInjection;
|
|
|
|
/// <summary>
|
|
/// Used as a the primary location for IOC type registration for e-suite.
|
|
/// </summary>
|
|
internal class CoreRegistrationModule : ESuiteModule
|
|
{
|
|
/// <summary>
|
|
/// Use the builder to register all the types and interfaces that the API requires to operate properly.
|
|
/// </summary>
|
|
/// <param name="builder"></param>
|
|
protected override void Load(ContainerBuilder builder)
|
|
{
|
|
base.Load(builder);
|
|
|
|
builder.RegisterType<SqlEsuiteDatabaseDbContext>().As<IEsuiteDatabaseDbContext>().InstancePerLifetimeScope();
|
|
//builder.RegisterType<UtcClock>().As<IClock>().SingleInstance();
|
|
}
|
|
} |