Class DefaultCatalogFacade
- java.lang.Object
-
- de.hybris.platform.commercefacades.catalog.impl.DefaultCatalogFacade
-
- All Implemented Interfaces:
CatalogFacade
public class DefaultCatalogFacade extends java.lang.Object implements CatalogFacade
Default implementation ofCatalogFacade
-
-
Constructor Summary
Constructors Constructor Description DefaultCatalogFacade()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.List<CatalogData>
getAllCatalogsWithOptions(java.util.Set<CatalogOption> opts)
Returns catalog DTOs for all catalogs and options (BASIC, PRODUCTS, CATEGORIES)java.util.List<CatalogData>
getAllProductCatalogsForCurrentSite(java.util.Set<CatalogOption> opts)
Returns product catalogs for the current base siteprotected BaseSiteService
getBaseSiteService()
CatalogData
getCatalogByIdAndOptions(java.lang.String id, java.util.Set<CatalogOption> options)
Returns catalog DTO for catalog id and options (BASIC, PRODUCTS, CATEGORIES)protected ConfigurablePopulator<CatalogModel,CatalogData,CatalogOption>
getCatalogHierarchyPopulator()
protected CatalogService
getCatalogService()
CatalogVersionData
getCatalogVersionByIdAndOptions(java.lang.String catalogId, java.lang.String catalogVersionId, java.util.Set<CatalogOption> opts)
Returns catalog version DTO for catalog id, catalog version id and options (BASIC, PRODUCTS, CATEGORIES)protected ConfigurablePopulator<CatalogVersionModel,CatalogVersionData,CatalogOption>
getCatalogVersionPopulator()
protected CatalogVersionService
getCatalogVersionService()
CategoryHierarchyData
getCategoryById(java.lang.String catalogId, java.lang.String catalogVersionId, java.lang.String categoryId, PageOption page, java.util.Set<CatalogOption> opts)
Returns category DTO for catalog id, catalog version id and category code and options (BASIC, PRODUCTS)protected PageablePopulator<CategoryModel,CategoryHierarchyData,CatalogOption>
getCategoryHierarchyPopulator()
protected CategoryService
getCategoryService()
CatalogData
getProductCatalogForCurrentSite(java.lang.String catalogId, java.util.Set<CatalogOption> opts)
Returns current base site product catalog by idprotected CatalogModel
getProductCatalogModelForBaseSite(java.lang.String catalogId)
protected java.util.List<CatalogModel>
getProductCatalogModelsForBaseSite()
CatalogVersionData
getProductCatalogVersionForTheCurrentSite(java.lang.String catalogId, java.lang.String catalogVersionId, java.util.Set<CatalogOption> opts)
Returns catalog version DTO for catalog id, catalog version id, current base site and options (BASIC, PRODUCTS, CATEGORIES)protected CatalogVersionModel
getProductCatalogVersionModelForBaseSite(java.lang.String catalogId, java.lang.String catalogVersionId)
void
setBaseSiteService(BaseSiteService baseSiteService)
void
setCatalogHierarchyPopulator(ConfigurablePopulator<CatalogModel,CatalogData,CatalogOption> catalogHierarchyPopulator)
void
setCatalogService(CatalogService catalogService)
void
setCatalogVersionPopulator(ConfigurablePopulator<CatalogVersionModel,CatalogVersionData,CatalogOption> catalogVersionPopulator)
void
setCatalogVersionService(CatalogVersionService catalogVersionService)
void
setCategoryHierarchyPopulator(PageablePopulator<CategoryModel,CategoryHierarchyData,CatalogOption> categoryHierarchyPopulator)
void
setCategoryService(CategoryService categoryService)
-
-
-
Method Detail
-
getAllCatalogsWithOptions
public java.util.List<CatalogData> getAllCatalogsWithOptions(java.util.Set<CatalogOption> opts)
Description copied from interface:CatalogFacade
Returns catalog DTOs for all catalogs and options (BASIC, PRODUCTS, CATEGORIES)- Specified by:
getAllCatalogsWithOptions
in interfaceCatalogFacade
- Parameters:
opts
- the catalog options- Returns:
- the
List
ofCatalogData
-
getCatalogByIdAndOptions
public CatalogData getCatalogByIdAndOptions(java.lang.String id, java.util.Set<CatalogOption> options)
Description copied from interface:CatalogFacade
Returns catalog DTO for catalog id and options (BASIC, PRODUCTS, CATEGORIES)- Specified by:
getCatalogByIdAndOptions
in interfaceCatalogFacade
- Parameters:
id
- the catalog idoptions
- the catalog options- Returns:
- the catalog
-
getCatalogVersionByIdAndOptions
public CatalogVersionData getCatalogVersionByIdAndOptions(java.lang.String catalogId, java.lang.String catalogVersionId, java.util.Set<CatalogOption> opts)
Description copied from interface:CatalogFacade
Returns catalog version DTO for catalog id, catalog version id and options (BASIC, PRODUCTS, CATEGORIES)- Specified by:
getCatalogVersionByIdAndOptions
in interfaceCatalogFacade
- Parameters:
catalogId
- the catalog idcatalogVersionId
- the catalog version idopts
- the catalog options- Returns:
- the catalog version
-
getCategoryById
public CategoryHierarchyData getCategoryById(java.lang.String catalogId, java.lang.String catalogVersionId, java.lang.String categoryId, PageOption page, java.util.Set<CatalogOption> opts)
Description copied from interface:CatalogFacade
Returns category DTO for catalog id, catalog version id and category code and options (BASIC, PRODUCTS)- Specified by:
getCategoryById
in interfaceCatalogFacade
- Parameters:
catalogId
- the catalog idcatalogVersionId
- the catalog version idcategoryId
- the category idpage
- the page optionsopts
- the catalog options- Returns:
- the category represented by an instance of
CategoryHierarchyData
-
getAllProductCatalogsForCurrentSite
public java.util.List<CatalogData> getAllProductCatalogsForCurrentSite(java.util.Set<CatalogOption> opts)
Description copied from interface:CatalogFacade
Returns product catalogs for the current base site- Specified by:
getAllProductCatalogsForCurrentSite
in interfaceCatalogFacade
- Parameters:
opts
- the catalog options- Returns:
- the
List
ofCatalogData
-
getProductCatalogForCurrentSite
public CatalogData getProductCatalogForCurrentSite(java.lang.String catalogId, java.util.Set<CatalogOption> opts)
Description copied from interface:CatalogFacade
Returns current base site product catalog by id- Specified by:
getProductCatalogForCurrentSite
in interfaceCatalogFacade
- Parameters:
catalogId
- the catalog idopts
- the catalog options- Returns:
- the product catalog
-
getProductCatalogVersionForTheCurrentSite
public CatalogVersionData getProductCatalogVersionForTheCurrentSite(java.lang.String catalogId, java.lang.String catalogVersionId, java.util.Set<CatalogOption> opts)
Description copied from interface:CatalogFacade
Returns catalog version DTO for catalog id, catalog version id, current base site and options (BASIC, PRODUCTS, CATEGORIES)- Specified by:
getProductCatalogVersionForTheCurrentSite
in interfaceCatalogFacade
- Parameters:
catalogId
- the catalog idcatalogVersionId
- the catalog version idopts
- the catalog options- Returns:
- the product catalog version
-
getProductCatalogModelsForBaseSite
protected java.util.List<CatalogModel> getProductCatalogModelsForBaseSite()
-
getProductCatalogModelForBaseSite
protected CatalogModel getProductCatalogModelForBaseSite(java.lang.String catalogId)
-
getProductCatalogVersionModelForBaseSite
protected CatalogVersionModel getProductCatalogVersionModelForBaseSite(java.lang.String catalogId, java.lang.String catalogVersionId)
-
setCatalogHierarchyPopulator
public void setCatalogHierarchyPopulator(ConfigurablePopulator<CatalogModel,CatalogData,CatalogOption> catalogHierarchyPopulator)
-
setCatalogService
public void setCatalogService(CatalogService catalogService)
-
setCatalogVersionPopulator
public void setCatalogVersionPopulator(ConfigurablePopulator<CatalogVersionModel,CatalogVersionData,CatalogOption> catalogVersionPopulator)
-
setCatalogVersionService
public void setCatalogVersionService(CatalogVersionService catalogVersionService)
-
setCategoryService
public void setCategoryService(CategoryService categoryService)
-
setCategoryHierarchyPopulator
public void setCategoryHierarchyPopulator(PageablePopulator<CategoryModel,CategoryHierarchyData,CatalogOption> categoryHierarchyPopulator)
-
setBaseSiteService
public void setBaseSiteService(BaseSiteService baseSiteService)
-
getCatalogService
protected CatalogService getCatalogService()
-
getCategoryService
protected CategoryService getCategoryService()
-
getCatalogVersionService
protected CatalogVersionService getCatalogVersionService()
-
getCatalogHierarchyPopulator
protected ConfigurablePopulator<CatalogModel,CatalogData,CatalogOption> getCatalogHierarchyPopulator()
-
getCatalogVersionPopulator
protected ConfigurablePopulator<CatalogVersionModel,CatalogVersionData,CatalogOption> getCatalogVersionPopulator()
-
getCategoryHierarchyPopulator
protected PageablePopulator<CategoryModel,CategoryHierarchyData,CatalogOption> getCategoryHierarchyPopulator()
-
getBaseSiteService
protected BaseSiteService getBaseSiteService()
-
-