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); }
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); }