Esempio n. 1
0
        public static void RegisterDatabase(IContainer container)
        {
            var mainDb = new MainDatabase(container.Resolve <IDbFactory>().Create());

            container.Register <IMainDatabase>(mainDb);

            var logDb = new LogDatabase(container.Resolve <IDbFactory>().Create(MigrationType.Log));

            container.Register <ILogDatabase>(logDb);
        }
Esempio n. 2
0
        public static void RegisterDatabase(IContainer container)
        {
            var mainDb = new MainDatabase(container.Resolve<IDbFactory>().Create());

            container.Register<IMainDatabase>(mainDb);

            var logDb = new LogDatabase(container.Resolve<IDbFactory>().Create(MigrationType.Log));

            container.Register<ILogDatabase>(logDb);
        }