예제 #1
0
		public object Get(CachedMovies request)
		{
			var service = base.ResolveService<MoviesService>();

			return base.RequestContext.ToOptimizedResultUsingCache(
				this.GetCacheClient(), UrnId.Create<Movies>(request.Genre ?? "all"), () =>
				{
					return (MoviesResponse)service.Get(new Movies { Genre = request.Genre });
				});
		}
        public object Get(CachedMovies request)
        {
            var service = base.ResolveService <MoviesService>();

            return(base.Request.ToOptimizedResultUsingCache(
                       this.GetCacheClient(), UrnId.Create <Movies>(request.Genre ?? "all"), () =>
            {
                return (MoviesResponse)service.Get(new Movies {
                    Genre = request.Genre
                });
            }));
        }