예제 #1
0
        public Startup(IConfiguration configuration)
        {
            Configuration = configuration;

            Startup.TileSources = Utils.GetTileSetConfigurations(this.Configuration)
                                  .ToDictionary(c => c.Name, c => TileSourceFabric.CreateTileSource(c));
        }
        public Startup()
        {
            var builder = new ConfigurationBuilder()
                          .AddJsonFile("appsettings.json");

            this.Configuration = builder.Build();
            // TODO: check and log configuration errors
            Startup.TileSources = Utils.GetTileSetConfigurations(this.Configuration)
                                  .ToDictionary(c => c.Name, c => TileSourceFabric.CreateTileSource(c));
        }