Class DefaultPersistenceService
java.lang.Object
de.hybris.platform.odata2services.odata.persistence.impl.DefaultPersistenceService
- All Implemented Interfaces:
PersistenceService
Default implementation for
PersistenceService-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.apache.olingo.odata2.api.ep.entry.ODataEntrycreateEntityData(StorageRequest storageRequest) Create or update a commerce suite item and return it as an ODataEntryvoiddeleteItem(ItemLookupRequest lookupRequest) Deletes the item matching the conditions of the specified requestprotected List<ItemSearchRequestValidator>Deprecated, for removal: This API element is subject to removal in a future version.validators are not used by this service anymore.ItemLookupResult<org.apache.olingo.odata2.api.ep.entry.ODataEntry>getEntities(ItemLookupRequest lookupRequest, ConversionOptions options) Searches for items matching the conditions of the specified requestorg.apache.olingo.odata2.api.ep.entry.ODataEntrygetEntityData(ItemLookupRequest lookupRequest, ConversionOptions options) Get a commerce suite item as an ODataEntryprotected ContextItemModelServiceDeprecated, for removal: This API element is subject to removal in a future version.not used anymoreprotected ModelEntityServiceprotected ModelServiceprotected PersistHookExecutorDeprecated, for removal: This API element is subject to removal in a future version.not used since persistence hooks have moved toDefaultItemPersistenceServiceprotected SessionServiceDeprecated, for removal: This API element is subject to removal in a future version.not used anymoreprotected org.springframework.transaction.support.TransactionTemplateDeprecated, for removal: This API element is subject to removal in a future version.not used anymorevoidsetDeleteItemValidators(List<ItemSearchRequestValidator> deleteItemValidators) Deprecated, for removal: This API element is subject to removal in a future version.used only in deprecateddeleteItem(ItemLookupRequest)method and will be removed together with that method.voidDeprecated, for removal: This API element is subject to removal in a future version.not used anymorevoidsetItemSearchService(ItemSearchService service) voidsetModelEntityService(ModelEntityService service) voidsetModelService(ModelService service) voidvoidsetPersistHookRegistry(PersistHookExecutor registry) Deprecated, for removal: This API element is subject to removal in a future version.not used since persistence hooks have moved toDefaultItemPersistenceServicevoidsetSessionService(SessionService sessionService) Deprecated, for removal: This API element is subject to removal in a future version.not used anymorevoidsetTransactionTemplate(org.springframework.transaction.support.TransactionTemplate transactionTemplate) Deprecated, for removal: This API element is subject to removal in a future version.not used anymore
-
Constructor Details
-
DefaultPersistenceService
public DefaultPersistenceService()
-
-
Method Details
-
createEntityData
public org.apache.olingo.odata2.api.ep.entry.ODataEntry createEntityData(StorageRequest storageRequest) throws org.apache.olingo.odata2.api.edm.EdmException Description copied from interface:PersistenceServiceCreate or update a commerce suite item and return it as an ODataEntry- Specified by:
createEntityDatain interfacePersistenceService- Parameters:
storageRequest- Parameter object that holds values for creating or updating an item.- Returns:
- the ODataEntry that was created or updated
- Throws:
org.apache.olingo.odata2.api.edm.EdmException- when not being able to persist the given info
-
getEntityData
public org.apache.olingo.odata2.api.ep.entry.ODataEntry getEntityData(ItemLookupRequest lookupRequest, ConversionOptions options) Description copied from interface:PersistenceServiceGet a commerce suite item as an ODataEntry- Specified by:
getEntityDatain interfacePersistenceService- Parameters:
lookupRequest- Parameter object that holds values for getting an item.options- Parameter that indicates options to be used during item conversion.- Returns:
- the ODataEntry that was required
-
getEntities
public ItemLookupResult<org.apache.olingo.odata2.api.ep.entry.ODataEntry> getEntities(ItemLookupRequest lookupRequest, ConversionOptions options) Description copied from interface:PersistenceServiceSearches for items matching the conditions of the specified request- Specified by:
getEntitiesin interfacePersistenceService- Parameters:
lookupRequest- specifies what items need to be found and conditions for matching the items existing in the platform.options- Parameter that indicates options to be used during item conversion- Returns:
- result of searching for ODataEntries matching the specified request conditions in the platform
-
deleteItem
Description copied from interface:PersistenceServiceDeletes the item matching the conditions of the specified request- Specified by:
deleteItemin interfacePersistenceService- Parameters:
lookupRequest- Parameter object that holds values for searching for an item.
-
getModelEntityService
-
setModelEntityService
-
setItemSearchService
-
getModelService
-
setModelService
-
getPersistHookRegistry
Deprecated, for removal: This API element is subject to removal in a future version.not used since persistence hooks have moved toDefaultItemPersistenceService -
setPersistenceService
-
setPersistHookRegistry
@Deprecated(since="2205", forRemoval=true) public void setPersistHookRegistry(PersistHookExecutor registry) Deprecated, for removal: This API element is subject to removal in a future version.not used since persistence hooks have moved toDefaultItemPersistenceService -
getSessionService
Deprecated, for removal: This API element is subject to removal in a future version.not used anymore -
setSessionService
@Deprecated(since="2205", forRemoval=true) public void setSessionService(SessionService sessionService) Deprecated, for removal: This API element is subject to removal in a future version.not used anymore -
getTransactionTemplate
@Deprecated(since="2205", forRemoval=true) protected org.springframework.transaction.support.TransactionTemplate getTransactionTemplate()Deprecated, for removal: This API element is subject to removal in a future version.not used anymore -
setTransactionTemplate
@Deprecated(since="2205", forRemoval=true) public void setTransactionTemplate(org.springframework.transaction.support.TransactionTemplate transactionTemplate) Deprecated, for removal: This API element is subject to removal in a future version.not used anymore -
getItemModelService
Deprecated, for removal: This API element is subject to removal in a future version.not used anymore -
setItemModelService
@Deprecated(since="2205", forRemoval=true) public void setItemModelService(ContextItemModelService service) Deprecated, for removal: This API element is subject to removal in a future version.not used anymore -
getDeleteItemValidators
@Deprecated(since="2205", forRemoval=true) protected List<ItemSearchRequestValidator> getDeleteItemValidators()Deprecated, for removal: This API element is subject to removal in a future version.validators are not used by this service anymore. Custom validators can be plugged intoDefaultItemDeletionService.setDeleteItemValidators(List)- See Also:
-
setDeleteItemValidators
@Deprecated(since="2205", forRemoval=true) public void setDeleteItemValidators(List<ItemSearchRequestValidator> deleteItemValidators) Deprecated, for removal: This API element is subject to removal in a future version.used only in deprecateddeleteItem(ItemLookupRequest)method and will be removed together with that method. Custom validators can be plugged intoDefaultItemDeletionService.setDeleteItemValidators(List)- See Also:
-