Exemple #1
0
        /// <summary>
        /// Posts the specified request.
        /// </summary>
        /// <param name="request">The request.</param>
        public void Post(MarkItemByNameFavorite request)
        {
            var pathInfo = PathInfo.Parse(RequestContext.PathInfo);
            var type     = pathInfo.GetArgumentValue <string>(3);

            var task = MarkFavorite(request.UserId, type, request.Name, true);

            Task.WaitAll(task);
        }
Exemple #2
0
        /// <summary>
        /// Posts the specified request.
        /// </summary>
        /// <param name="request">The request.</param>
        public object Post(MarkItemByNameFavorite request)
        {
            var pathInfo = PathInfo.Parse(RequestContext.PathInfo);
            var type     = pathInfo.GetArgumentValue <string>(3);

            var task = MarkFavorite(request.UserId, type, request.Name, true);

            return(ToOptimizedResult(task.Result));
        }
        /// <summary>
        /// Posts the specified request.
        /// </summary>
        /// <param name="request">The request.</param>
        public void Post(MarkItemByNameFavorite request)
        {
            var pathInfo = PathInfo.Parse(RequestContext.PathInfo);
            var type = pathInfo.GetArgumentValue<string>(3);

            var task = MarkFavorite(request.UserId, type, request.Name, true);

            Task.WaitAll(task);
        }