Exemplo n.º 1
0
        public void Init()
        {
            var kernel = new StandardKernel();

            DbConnection = DbConnectionFactory.CreateTransient();
            kernel.Bind <ILoanApplicationContext>().To <LoanApplicationContext>()
            .WithConstructorArgument("connection", DbConnection);
            kernel.Bind <ILoanApplicationUnitOfWork>().To <LoanApplicationUnitOfWork>();
            kernel.Bind <ILoanService>().To <LoanService>();

            LoanContext    = kernel.Get <ILoanApplicationContext>();
            LoanService    = kernel.Get <ILoanService>();
            LoanUnitOfWork = kernel.Get <ILoanApplicationUnitOfWork>();
        }
 public LoanApplicationUnitOfWork(ILoanApplicationContext context) : base((DbContext)context)
 {
 }
Exemplo n.º 3
0
 public LoanApplicationRespository(ILoanApplicationContext context) : base((DbContext)context)
 {
 }