Exemple #1
0
        /// <summary>
        /// Gets the item by name image infos.
        /// </summary>
        /// <param name="request">The request.</param>
        /// <returns>Task{List{ImageInfo}}.</returns>
        private List <ImageInfo> GetItemByNameImageInfos(GetItemByNameImageInfos request)
        {
            var pathInfo = PathInfo.Parse(RequestContext.PathInfo);
            var type     = pathInfo.GetArgumentValue <string>(0);

            var item = GetItemByName(request.Name, type, _libraryManager);

            return(GetItemImageInfos(item));
        }
        /// <summary>
        /// Gets the item by name image infos.
        /// </summary>
        /// <param name="request">The request.</param>
        /// <returns>Task{List{ImageInfo}}.</returns>
        public async Task<List<ImageInfo>> GetItemByNameImageInfos(GetItemByNameImageInfos request)
        {
            var pathInfo = PathInfo.Parse(RequestContext.PathInfo);
            var type = pathInfo.GetArgumentValue<string>(0);

            var item = await GetItemByName(request.Name, type, _libraryManager).ConfigureAwait(false);

            return await GetItemImageInfos(item).ConfigureAwait(false);
        }
Exemple #3
0
        public object Get(GetItemByNameImageInfos request)
        {
            var result = GetItemByNameImageInfos(request);

            return(ToOptimizedResult(result));
        }
        public object Get(GetItemByNameImageInfos request)
        {
            var result = GetItemByNameImageInfos(request);

            return(ToOptimizedSerializedResultUsingCache(result));
        }