Esempio n. 1
0
        public DefaultCacheResolver(ICacheProvider cacheProvider, ILogger logger)
        {
            if (cacheProvider == null)
            {
                throw new ArgumentNullException(nameof(cacheProvider));
            }

            this.cacheProvider      = cacheProvider;
            this.syncCacheProvider  = cacheProvider as ISynchronousCacheProvider;
            this.asyncCacheProvider = cacheProvider as IAsynchronousCacheProvider;
            this.logger             = logger;
            this.typeLookup         = new ResourceTypeLookup();
        }
        public DefaultCacheResolver(ICacheProvider cacheProvider, ILogger logger)
        {
            if (cacheProvider == null)
            {
                throw new ArgumentNullException(nameof(cacheProvider));
            }

            this.cacheProvider = cacheProvider;
            this.syncCacheProvider = cacheProvider as ISynchronousCacheProvider;
            this.asyncCacheProvider = cacheProvider as IAsynchronousCacheProvider;
            this.logger = logger;
            this.typeLookup = new ResourceTypeLookup();
        }