/** * Deletes the product type by providing the product type ID. * * <p> * * <pre><code> * ProductType producttype = new ProductType(); * producttype.deleteProductType( productTypeId); * </code></pre> * * @param productTypeId Identifier of the product type. * @param dataViewMode DataViewMode * @return */ public void deleteProductType(Integer productTypeId) throws Exception { MozuClient client = com.mozu.api.clients.commerce.catalog.admin.attributedefinition.ProductTypeClient .deleteProductTypeClient(_dataViewMode, productTypeId); client.setContext(_apiContext); client.executeRequest(); client.cleanupHttpConnection(); }
/** * Retrieves the details of the product type specified in the request. * * <p> * * <pre><code> * ProductType producttype = new ProductType(); * ProductType productType = producttype.getProductType( productTypeId, responseFields); * </code></pre> * * @param productTypeId Identifier of the product type. * @param responseFields Use this field to include those fields which are not included by default. * @param dataViewMode DataViewMode * @return com.mozu.api.contracts.productadmin.ProductType * @see com.mozu.api.contracts.productadmin.ProductType */ public com.mozu.api.contracts.productadmin.ProductType getProductType( Integer productTypeId, String responseFields) throws Exception { MozuClient<com.mozu.api.contracts.productadmin.ProductType> client = com.mozu.api.clients.commerce.catalog.admin.attributedefinition.ProductTypeClient .getProductTypeClient(_dataViewMode, productTypeId, responseFields); client.setContext(_apiContext); client.executeRequest(); return client.getResult(); }
/** * Retrieves a list of product types according to any specified filter criteria and sort options. * * <p> * * <pre><code> * ProductType producttype = new ProductType(); * ProductTypeCollection productTypeCollection = producttype.getProductTypes( startIndex, pageSize, sortBy, filter, responseFields); * </code></pre> * * @param filter A set of filter expressions representing the search parameters for a query: * eq=equals, ne=not equals, gt=greater than, lt = less than or equals, gt = greater than or * equals, lt = less than or equals, sw = starts with, or cont = contains. Optional. * @param pageSize The number of results to display on each page when creating paged results from * a query. The maximum value is 200. * @param responseFields Use this field to include those fields which are not included by default. * @param sortBy * @param startIndex * @param dataViewMode DataViewMode * @return com.mozu.api.contracts.productadmin.ProductTypeCollection * @see com.mozu.api.contracts.productadmin.ProductTypeCollection */ public com.mozu.api.contracts.productadmin.ProductTypeCollection getProductTypes( Integer startIndex, Integer pageSize, String sortBy, String filter, String responseFields) throws Exception { MozuClient<com.mozu.api.contracts.productadmin.ProductTypeCollection> client = com.mozu.api.clients.commerce.catalog.admin.attributedefinition.ProductTypeClient .getProductTypesClient( _dataViewMode, startIndex, pageSize, sortBy, filter, responseFields); client.setContext(_apiContext); client.executeRequest(); return client.getResult(); }