示例#1
0
        private async Task <ScItemsResponse> GetHomeItem(IReadItemActions session, string db = null)
        {
            if (db != null)
            {
                this.homeItemRequestBuilder.Database(db);
            }
            var response = await GetItemByIdWithRequestBuilder(this.homeItemRequestBuilder, session);

            return(response);
        }
示例#2
0
        private static async Task <ScItemsResponse> GetItemByIdWithRequestBuilder(IScopedRequestParametersBuilder <IReadItemsByIdRequest> requestBuilder, IReadItemActions session)
        {
            var request  = requestBuilder.Build();
            var response = await session.ReadItemAsync(request);

            return(response);
        }
    private static async Task<ScItemsResponse> GetItemByIdWithRequestBuilder(IScopedRequestParametersBuilder<IReadItemsByIdRequest> requestBuilder, IReadItemActions session)
    {
      var request = requestBuilder.Build();
      var response = await session.ReadItemAsync(request);

      return response;
    }
 private async Task<ScItemsResponse> GetHomeItem(IReadItemActions session, string db = null)
 {
   if (db != null)
   {
     this.homeItemRequestBuilder.Database(db);
   }
   var response = await GetItemByIdWithRequestBuilder(this.homeItemRequestBuilder, session);
   return response;
 }