Esempio n. 1
0
        public override void ConfigureServices(IServiceCollection services)
        {
            base.ConfigureServices(services);

            var startupOrderHelper = StartupOrderHelper.Instance();

            services.AddSingleton <IStartupOrderHelper>(sp => startupOrderHelper);
            services.AddSingleton <StartupOrderHelper>(sp => startupOrderHelper as StartupOrderHelper);

            var dbContextHelper = DbContextHelper.Instance;

            dbContextHelper.AddSupportSqlServer();
            dbContextHelper.AddSupportMySql();
            services.AddSingleton(dbContextHelper);
        }
Esempio n. 2
0
 public IStartupOrderHelper GetStartupOrderHelper()
 {
     return(StartupOrderHelper.Instance());
 }