Package de.hybris.platform.catalog
Interface CatalogService
-
- All Known Implementing Classes:
DefaultCatalogService
public interface CatalogService
Provides access to Catalogs, CatalogVersions and Session CatalogVersions- Spring Bean ID:
- catalogService
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description void
addSessionCatalogVersion(java.lang.String catalogId, java.lang.String catalogVersionName)
Deprecated.java.util.Collection<CatalogModel>
getAllCatalogs()
Returns allCatalogModel
s.<T extends CatalogModel>
java.util.Collection<T>getAllCatalogsOfType(java.lang.Class<T> catalogType)
Returns for the givenT
(upper bound CatalogModel) all catalogs ofT
defined in the systemCatalogModel
getCatalogForId(java.lang.String id)
Returns the catalog with the specifiedid
.CatalogVersionModel
getCatalogVersion(java.lang.String catalogId, java.lang.String catalogVersionName)
Deprecated.since ages - UseCatalogVersionService.getCatalogVersion(String, String)
CatalogModel
getDefaultCatalog()
Returns the default catalog basing onCatalogModel.DEFAULTCATALOG
property.void
setSessionCatalogVersion(java.lang.String catalogId, java.lang.String catalogVersionName)
Deprecated.since ages - useCatalogVersionService.setSessionCatalogVersion(String, String)
instead.
-
-
-
Method Detail
-
setSessionCatalogVersion
@Deprecated void setSessionCatalogVersion(java.lang.String catalogId, java.lang.String catalogVersionName)
Deprecated.since ages - useCatalogVersionService.setSessionCatalogVersion(String, String)
instead.Sets theCatalogVersionModel
specified bycatalogId
andcatalogVersionName
as the active CatalogVersion of the current session. Previous set active CatalogVersions are replaced.- Parameters:
catalogId
- the id of the Catalog the CatalogVersion belongs tocatalogVersionName
- the version of the Catalog version- Throws:
UnknownIdentifierException
- if no CatalogVersion with the specified catalog id and version existsAmbiguousIdentifierException
- if more than one CatalogVersion is found with the specified catalog id and versionjava.lang.IllegalArgumentException
- ifcatalogId
orcatalogVersionName
isnull
-
addSessionCatalogVersion
@Deprecated void addSessionCatalogVersion(java.lang.String catalogId, java.lang.String catalogVersionName)
Deprecated.Adds theCatalogVersionModel
specified bycatalogId
andcatalogVersionName
to the current active Session CatalogVersions.- Parameters:
catalogId
- the id of the Catalog the CatalogVersion belongs tocatalogVersionName
- the version of the Catalog version- Throws:
UnknownIdentifierException
- if no CatalogVersion with the specified catalog id and version existsAmbiguousIdentifierException
- if more than one CatalogVersion is found with the specified catalog id and versionjava.lang.IllegalArgumentException
- ifcatalogId
orcatalogVersionName
isnull
-
getCatalogVersion
@Deprecated CatalogVersionModel getCatalogVersion(java.lang.String catalogId, java.lang.String catalogVersionName)
Deprecated.since ages - UseCatalogVersionService.getCatalogVersion(String, String)
- Parameters:
catalogId
- the id for the catalogcatalogVersionName
- the version string for the catalog version- Returns:
- the CatalogVersion with the specified catalog id and version
- Throws:
UnknownIdentifierException
- if no CatalogVersion with the specified catalog id and version existsAmbiguousIdentifierException
- if more than one CatalogVersion is found with the specified catalog id and versionjava.lang.IllegalArgumentException
- ifcatalogId
orcatalogVersionName
isnull
-
getAllCatalogs
java.util.Collection<CatalogModel> getAllCatalogs()
Returns allCatalogModel
s.- Returns:
- an empty collection if no CatalogModel were found.
-
getAllCatalogsOfType
<T extends CatalogModel> java.util.Collection<T> getAllCatalogsOfType(java.lang.Class<T> catalogType)
Returns for the givenT
(upper bound CatalogModel) all catalogs ofT
defined in the system- Type Parameters:
T
- This could be aClassificationSystemModel
or aCatalogModel
- Returns:
- an empty collection if no
ClassificationSystemModel
s orCatalogModel
were found. - Throws:
java.lang.IllegalArgumentException
- ifcatalogType
isnull
-
getCatalogForId
CatalogModel getCatalogForId(java.lang.String id)
Returns the catalog with the specifiedid
.- Returns:
- the catalog with the specified id.
- Throws:
UnknownIdentifierException
- if no Catalog with the specifiedid
is foundAmbiguousIdentifierException
- if more than one Catalog is found with the specifiedid
java.lang.IllegalArgumentException
- ifid
isnull
-
getDefaultCatalog
CatalogModel getDefaultCatalog()
Returns the default catalog basing onCatalogModel.DEFAULTCATALOG
property. If multiple catalogs the one created the latest will be returned.- Returns:
- default
CatalogModel
, or null in case no default catalog was found.
-
-