public KnownTileLayerConfiguration(PermaCacheType permaCacheType, string fileCacheRoot,
            KnownTileSource tileSource, string apiKey)
            : base(permaCacheType, Path.Combine(BruTileLayerPlugin.Settings.PermaCacheRoot, tileSource.ToString()))
        {
            _knownTileSource = tileSource;
            _apiKey = apiKey;
            /*
            if (tileServers == KnownTileServers.Custom)
                throw new NotSupportedException();
            */

            TileSource = KnownTileSources.Create(tileSource, apiKey);
            TileCache = CreateTileCache();
            LegendText = tileSource.ToString();

            _tileFetcher = new TileFetcher(ReflectionHelper.Reflect(TileSource),
                                           BruTileLayerPlugin.Settings.MemoryCacheMinimum,
                                           BruTileLayerPlugin.Settings.MemoryCacheMaximum,
                                           TileCache);
        }
        public KnownTileLayerConfiguration(PermaCacheType permaCacheType, string fileCacheRoot,
                                           KnownTileSource tileSource, string apiKey)
            : base(permaCacheType, Path.Combine(BruTileLayerPlugin.Settings.PermaCacheRoot, tileSource.ToString()))
        {
            _knownTileSource = tileSource;
            _apiKey          = apiKey;

            /*
             * if (tileServers == KnownTileServers.Custom)
             *  throw new NotSupportedException();
             */

            TileSource = KnownTileSources.Create(tileSource, apiKey);
            TileCache  = CreateTileCache();
            LegendText = tileSource.ToString();

            _tileFetcher = new TileFetcher(ReflectionHelper.Reflect(TileSource),
                                           BruTileLayerPlugin.Settings.MemoryCacheMinimum,
                                           BruTileLayerPlugin.Settings.MemoryCacheMaximum,
                                           TileCache);
        }
 protected PermaCacheConfiguration(PermaCacheType permaCacheType, string permaCacheRoot)
 {
     _permaCacheType = permaCacheType;
     _permaCacheRoot = permaCacheRoot;
 }