Class DefaultCmsItemModelUniqueIdentifierConverter
java.lang.Object
de.hybris.platform.cmsfacades.uniqueidentifier.functions.DefaultCmsItemModelUniqueIdentifierConverter
- All Implemented Interfaces:
UniqueIdentifierConverter<CMSItemModel>
public class DefaultCmsItemModelUniqueIdentifierConverter
extends Object
implements UniqueIdentifierConverter<CMSItemModel>
Default implementation for conversion of
CMSItemModel-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionconvert(CMSItemModel cmsItemModel) Convert an ItemModel object to the correspondingItemDatainstance.protected CMSItemModelfindItemByComposedKey(EncodedItemComposedKey itemComposedKey, CatalogVersionModel catalogVersion) protected CMSItemModelfindItemById(ItemData itemData) protected CatalogVersionServiceprotected CMSAdminItemServiceprotected org.springframework.beans.factory.ObjectFactory<ItemData>Returns the item typeItemModel#getItemTypewhere the converter should be applied to.protected StringgetUniqueIdentifier(CMSItemModel cmsItemModel) Returns the unique identifier using the encoded compose key class.voidsetCatalogVersionService(CatalogVersionService catalogVersionService) voidsetCmsAdminItemService(CMSAdminItemService cmsAdminItemService) voidsetItemDataDataFactory(org.springframework.beans.factory.ObjectFactory<ItemData> itemDataDataFactory)
-
Constructor Details
-
DefaultCmsItemModelUniqueIdentifierConverter
public DefaultCmsItemModelUniqueIdentifierConverter()
-
-
Method Details
-
getItemType
Description copied from interface:UniqueIdentifierConverterReturns the item typeItemModel#getItemTypewhere the converter should be applied to.- Specified by:
getItemTypein interfaceUniqueIdentifierConverter<CMSItemModel>- Returns:
- item type
-
convert
Description copied from interface:UniqueIdentifierConverterConvert an ItemModel object to the correspondingItemDatainstance.- Specified by:
convertin interfaceUniqueIdentifierConverter<CMSItemModel>- Parameters:
cmsItemModel- - the item model entity that will be converted.- Returns:
- an instance of the
ItemDataclass that corresponds to the givenItemModelUniqueIdentifierConverter.getItemType().
-
convert
Description copied from interface:UniqueIdentifierConverter- Specified by:
convertin interfaceUniqueIdentifierConverter<CMSItemModel>- Parameters:
itemData- - the item data instance that will be used in the conversion.- Returns:
- the
ItemModelentity that corresponds to the givenItemDataUniqueIdentifierConverter.getItemType().
-
findItemByComposedKey
protected CMSItemModel findItemByComposedKey(EncodedItemComposedKey itemComposedKey, CatalogVersionModel catalogVersion) -
findItemById
-
getUniqueIdentifier
Returns the unique identifier using the encoded compose key class. See more details hereEncodedItemComposedKey.- Parameters:
cmsItemModel- the cms item model we want to extract the unique identifier.- Returns:
- the encoded unique identifier.
- See Also:
-
setCmsAdminItemService
-
getCmsAdminItemService
-
getCatalogVersionService
-
setCatalogVersionService
-
getItemDataDataFactory
-
setItemDataDataFactory
public void setItemDataDataFactory(org.springframework.beans.factory.ObjectFactory<ItemData> itemDataDataFactory)
-