public IAsyncResult BeginGetProductCategories(GetProductCategoriesRequest GetProductCategoriesRequest, AsyncCallback callback, object asyncState) { return this.BeginInvoke("GetProductCategories", new object[1] { (object) GetProductCategoriesRequest }, callback, asyncState); }
public IList<productCategoryType> GetProductCategories(sessionType session, string region, int? rootCategory, bool? includeChilds) { GetProductCategoriesRequest GetProductCategoriesRequest = new GetProductCategoriesRequest(); GetProductCategoriesRequest.connectId = session.connectId; GetProductCategoriesRequest.region = region; if (rootCategory.HasValue) { GetProductCategoriesRequest.rootCategory = rootCategory.Value; GetProductCategoriesRequest.rootCategorySpecified = true; } if (includeChilds.HasValue) { GetProductCategoriesRequest.includeChilds = includeChilds.Value; GetProductCategoriesRequest.includeChildsSpecified = true; } GetProductCategoriesResponse productCategories = this.publisherService.GetProductCategories(GetProductCategoriesRequest); if (productCategories == null || productCategories.categories == null) return (IList<productCategoryType>) null; else return (IList<productCategoryType>) Enumerable.ToList<productCategoryType>((IEnumerable<productCategoryType>) productCategories.categories); }