Class DummyConfigurationProvider
java.lang.Object
de.hybris.platform.sap.productconfig.runtime.interf.impl.DummyConfigurationProvider
- All Implemented Interfaces:
ConfigurationProvider
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionchangeConfiguration(ConfigModel model) Checks the configuration model for changes since the last update and will send only the changes to the configuration engine, if any.Creates a configuration from the configuration in external format which can be provided from outside, e.g.createConfigurationFromExternalSource(KBKey kbKey, String extConfig) Creates a configuration from an XML string containing the configuration in external format.createDefaultConfiguration(KBKey kbKey) Creates a default configuration for the required knowledge base.booleanisKbForDateExists(String productCode, Date kbDate) voidreleaseSession(String configId) Releases the configuration sessions identified by the provided ID and all associated resources.voidreleaseSession(String configId, String version) Releases the configuration sessions identified by the provided ID and all associated resources.retrieveConfigurationModel(String configId) Retrieve the current state of the configuration model for the requestedconfigId.retrieveExternalConfiguration(String configId) Retrieve the current state of the configuration for the requestedconfigIdas an XML string containing the configuration in external format.voidsetI18NService(I18NService i18nService) booleanupdateConfiguration(ConfigModel model) Checks the configuration model for changes since the last update and will send only the changes to the configuration engine, if any.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface de.hybris.platform.sap.productconfig.runtime.interf.ConfigurationProvider
enrichModelWithGroup, extractKbKey, isKbVersionExists, isKbVersionValid, isReadDomainValuesOnDemandSupported, retrieveConfigurationFromVariant, retrieveConfigurationModel, retrieveConfigurationModel
-
Constructor Details
-
DummyConfigurationProvider
public DummyConfigurationProvider()
-
-
Method Details
-
createDefaultConfiguration
Description copied from interface:ConfigurationProviderCreates a default configuration for the required knowledge base. The knowledge base (KB) can be identified e.g. via the product code or via the KB name, version and logical system.- Specified by:
createDefaultConfigurationin interfaceConfigurationProvider- Parameters:
kbKey- Information needed to identify a knowledge base- Returns:
- The configurable product with default configuration
-
updateConfiguration
Description copied from interface:ConfigurationProviderChecks the configuration model for changes since the last update and will send only the changes to the configuration engine, if any.- Specified by:
updateConfigurationin interfaceConfigurationProvider- Parameters:
model- Updated model- Returns:
true, only if it was necessary to send an update to the configuration engine
-
retrieveConfigurationModel
Description copied from interface:ConfigurationProviderRetrieve the current state of the configuration model for the requestedconfigId.- Specified by:
retrieveConfigurationModelin interfaceConfigurationProvider- Parameters:
configId- Unique configuration ID- Returns:
- The actual configuration
-
retrieveExternalConfiguration
Description copied from interface:ConfigurationProviderRetrieve the current state of the configuration for the requestedconfigIdas an XML string containing the configuration in external format.- Specified by:
retrieveExternalConfigurationin interfaceConfigurationProvider- Parameters:
configId- Unique configuration ID- Returns:
- The actual configuration as XML string
-
getI18NService
-
setI18NService
-
createConfigurationFromExternalSource
Description copied from interface:ConfigurationProviderCreates a configuration from the configuration in external format which can be provided from outside, e.g. from the configuration prepared in the back end.
This API does _not_ force the KB related attributes to be existing. In case only the product ID is provided, a matching KB version is determined.- Specified by:
createConfigurationFromExternalSourcein interfaceConfigurationProvider- Parameters:
extConfig- External configuration in external format- Returns:
- Configuration model
-
createConfigurationFromExternalSource
Description copied from interface:ConfigurationProviderCreates a configuration from an XML string containing the configuration in external format.
This API requires the KB related attributes as part of the external configuration to be available, they are directly forwarded to the configuration engine.- Specified by:
createConfigurationFromExternalSourcein interfaceConfigurationProvider- Parameters:
kbKey- Information needed to create a knowledge baseextConfig- External configuration as XML string- Returns:
- Configuration model
-
releaseSession
Description copied from interface:ConfigurationProviderReleases the configuration sessions identified by the provided ID and all associated resources. Accessing the session afterwards is not possible anymore.- Specified by:
releaseSessionin interfaceConfigurationProvider- Parameters:
configId- session id
-
isKbForDateExists
- Specified by:
isKbForDateExistsin interfaceConfigurationProvider- Returns:
trueonly if a valid KBVersion exists for the given product and date.
-
changeConfiguration
Description copied from interface:ConfigurationProviderChecks the configuration model for changes since the last update and will send only the changes to the configuration engine, if any. The version of the runtime configuration must be included in the configuration model and the method returns the new version after the update.- Specified by:
changeConfigurationin interfaceConfigurationProvider- Parameters:
model- Updated model- Returns:
- new configuration runtime version if update successful, otherwise null
- Throws:
ConfigurationEngineException
-
releaseSession
Description copied from interface:ConfigurationProviderReleases the configuration sessions identified by the provided ID and all associated resources. Accessing the session afterwards is not possible anymore.- Specified by:
releaseSessionin interfaceConfigurationProvider- Parameters:
configId- session idversion- version of the runtime configuration
-