33 lines
1014 B
C#
33 lines
1014 B
C#
using GasStation.Repositories;
|
|
using GasStation.Repositories.Implementations;
|
|
using System.Drawing.Text;
|
|
using Unity;
|
|
|
|
namespace GasStation;
|
|
|
|
internal static class Program
|
|
{
|
|
/// <summary>
|
|
/// The main entry point for the application.
|
|
/// </summary>
|
|
[STAThread]
|
|
static void Main()
|
|
{
|
|
// To customize application configuration such as set high DPI settings or default font,
|
|
// see https://aka.ms/applicationconfiguration.
|
|
ApplicationConfiguration.Initialize();
|
|
Application.Run(CreateContainer().Resolve<FormGasStation>());
|
|
}
|
|
|
|
private static IUnityContainer CreateContainer()
|
|
{
|
|
var container = new UnityContainer();
|
|
|
|
container.RegisterType<IGasmanRepository, GasmanRepository>();
|
|
container.RegisterType<ISellingRepository,SellingRepository>();
|
|
container.RegisterType<ISupplierRepository, SupplierRepository>();
|
|
container.RegisterType<ISupplyRepository, SupplyRepository>();
|
|
|
|
return container;
|
|
}
|
|
} |