Class LegacyModeChecker
java.lang.Object
de.hybris.platform.promotions.util.legacy.LegacyModeChecker
- All Implemented Interfaces:
org.springframework.beans.factory.Aware,org.springframework.context.ApplicationContextAware
public class LegacyModeChecker
extends Object
implements org.springframework.context.ApplicationContextAware
Checks whether legacy mode enablement flag for the promotions correlates with the bean version being used in runtime
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcheck()Performs check whether legacy mode is enabledprotected voidprotected org.springframework.context.ApplicationContextprotected PromotionsServiceprotected PromotionsServiceprotected voidinit()protected booleanprotected voidprotected voidvoidsetApplicationContext(org.springframework.context.ApplicationContext applicationContext) voidsetLegacyModeEnabled(boolean legacyModeEnabled) voidsetLegacyPromotionsService(PromotionsService legacyPromotionsService) voidsetPromotionsService(PromotionsService promotionsService)
-
Constructor Details
-
LegacyModeChecker
public LegacyModeChecker()
-
-
Method Details
-
check
public void check()Performs check whether legacy mode is enabled- Throws:
LegacyException- if legacy mode is disabled
-
checkLegacyModeOnStartUp
protected void checkLegacyModeOnStartUp() -
init
@PostConstruct protected void init() -
logWarning
protected void logWarning() -
logErrorAndThrowException
protected void logErrorAndThrowException() -
getPromotionsService
-
setPromotionsService
-
getLegacyPromotionsService
-
setLegacyPromotionsService
-
getApplicationContext
protected org.springframework.context.ApplicationContext getApplicationContext() -
setApplicationContext
public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext) - Specified by:
setApplicationContextin interfaceorg.springframework.context.ApplicationContextAware
-
isLegacyModeEnabled
protected boolean isLegacyModeEnabled() -
setLegacyModeEnabled
public void setLegacyModeEnabled(boolean legacyModeEnabled)
-