protected override IRepositoryCachePolicy <IDictionaryItem, string> CreateCachePolicy()
            {
                var options = new RepositoryCachePolicyOptions
                {
                    //allow zero to be cached
                    GetAllCacheAllowZeroCount = true
                };

                return(new SingleItemsOnlyRepositoryCachePolicy <IDictionaryItem, string>(GlobalIsolatedCache, ScopeAccessor, options));
            }
            protected override IRepositoryCachePolicy <IDictionaryItem, string> CreateCachePolicy(IRuntimeCacheProvider runtimeCache)
            {
                var options = new RepositoryCachePolicyOptions
                {
                    //allow zero to be cached
                    GetAllCacheAllowZeroCount = true
                };

                return(new SingleItemsOnlyRepositoryCachePolicy <IDictionaryItem, string>(runtimeCache, options));
            }
示例#3
0
 public SingleItemsOnlyRepositoryCachePolicy(IAppPolicyCache cache, IScopeAccessor scopeAccessor, RepositoryCachePolicyOptions options)
     : base(cache, scopeAccessor, options)
 {
 }
示例#4
0
 public DefaultRepositoryCachePolicy(IAppPolicyCache cache, IScopeAccessor scopeAccessor, RepositoryCachePolicyOptions options)
     : base(cache, scopeAccessor) =>