Ejemplo n.º 1
0
 private ICacheKeySource GetKeyFromSource(ControllerContext filterContext)
 {
     ICacheKeySource source;
     switch (_source)
     {
         case CacheKeySource.Request:
             source = new RequestCacheKeySource(filterContext.RequestContext);
             break;
         default:
             throw new ArgumentOutOfRangeException();
     }
     return source;
 }
Ejemplo n.º 2
0
        private ICacheKeySource GetKeyFromSource(ControllerContext filterContext)
        {
            ICacheKeySource source;

            switch (_source)
            {
            case CacheKeySource.Request:
                source = new RequestCacheKeySource(filterContext.RequestContext);
                break;

            default:
                throw new ArgumentOutOfRangeException();
            }
            return(source);
        }