コード例 #1
0
        public SignalRDemoMigrationsDbContext CreateDbContext(string[] args)
        {
            SignalRDemoEfCoreEntityExtensionMappings.Configure();

            var configuration = BuildConfiguration();

            var builder = new DbContextOptionsBuilder <SignalRDemoMigrationsDbContext>()
                          .UseSqlServer(configuration.GetConnectionString("Default"));

            return(new SignalRDemoMigrationsDbContext(builder.Options));
        }
コード例 #2
0
 public override void PreConfigureServices(ServiceConfigurationContext context)
 {
     SignalRDemoEfCoreEntityExtensionMappings.Configure();
 }