Class DefaultStorageRequestFactory
java.lang.Object
de.hybris.platform.odata2services.odata.persistence.DefaultStorageRequestFactory
- All Implemented Interfaces:
StorageRequestFactory
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected IntegrationItemconvert(org.apache.olingo.odata2.api.processor.ODataContext context, org.apache.olingo.odata2.api.edm.EdmEntitySet entitySet, org.apache.olingo.odata2.api.ep.entry.ODataEntry entry) create(org.apache.olingo.odata2.api.processor.ODataContext oDataContext, String responseContentType, org.apache.olingo.odata2.api.edm.EdmEntitySet entitySet, org.apache.olingo.odata2.api.ep.entry.ODataEntry entry) Get the StorageRequest for persistence processingprotected ODataEntryToIntegrationItemConverterprotected ODataContextLanguageExtractorprotected booleanisItemCanBeCreated(org.apache.olingo.odata2.api.processor.ODataContext context) Determines whether the request insists on updating an existing item only or allows new item creation.protected booleanisReplaceAttributes(org.apache.olingo.odata2.api.processor.ODataContext oDataContext) Determines if the request is to replace the attributes provided in the payloadvoidvoidsetLocaleExtractor(ODataContextLanguageExtractor localeExtractor) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface de.hybris.platform.odata2services.odata.persistence.StorageRequestFactory
create
-
Constructor Details
-
DefaultStorageRequestFactory
public DefaultStorageRequestFactory()
-
-
Method Details
-
create
public StorageRequest create(org.apache.olingo.odata2.api.processor.ODataContext oDataContext, String responseContentType, org.apache.olingo.odata2.api.edm.EdmEntitySet entitySet, org.apache.olingo.odata2.api.ep.entry.ODataEntry entry) Description copied from interface:StorageRequestFactoryGet the StorageRequest for persistence processing- Specified by:
createin interfaceStorageRequestFactory- Parameters:
oDataContext- The ODataContext to be used.responseContentType- contentType to use.entitySet- EdmEntitySet to use.entry- ODataEntry to use.- Returns:
- The StorageRequest used for persistence
-
isReplaceAttributes
protected boolean isReplaceAttributes(org.apache.olingo.odata2.api.processor.ODataContext oDataContext) Determines if the request is to replace the attributes provided in the payload- Parameters:
oDataContext- Context used in making the decision- Returns:
true, replace attributes, otherwisefalse
-
isItemCanBeCreated
protected boolean isItemCanBeCreated(org.apache.olingo.odata2.api.processor.ODataContext context) Determines whether the request insists on updating an existing item only or allows new item creation.- Parameters:
context- context used in making the decision- Returns:
true, if the item can be created when it does not exist in the system;false, when new item cannot be created and only an existing item should be updated.
-
convert
protected IntegrationItem convert(org.apache.olingo.odata2.api.processor.ODataContext context, org.apache.olingo.odata2.api.edm.EdmEntitySet entitySet, org.apache.olingo.odata2.api.ep.entry.ODataEntry entry) throws org.apache.olingo.odata2.api.edm.EdmException - Throws:
org.apache.olingo.odata2.api.edm.EdmException
-
getLocaleExtractor
-
setLocaleExtractor
-
getEntryConverter
-
setEntryConverter
-