Пример #1
0
        public static AreaCacheDownload Create(IFileCache fileCache)
        {
            if (_instance != null)
            {
                if (_instance.FileCache.GetType() != fileCache.GetType())
                {
                    throw new ArgumentException($"Already initialized with fileCache type {fileCache}");
                }
                return(_instance);
            }
            var cacheLookup = CacheFileLookup.Create(new AzureFileCache().ListBoxes());
            var t           = new AreaCacheDownload(cacheLookup, fileCache);

            _instance = t;
            return(t);
        }
Пример #2
0
 private AreaCacheDownload(CacheFileLookup cacheFileLookup, IFileCache fileCache)
 {
     _cacheFileLookup = cacheFileLookup;
     FileCache        = fileCache;
 }