Class RuleEngineRuleValidateInterceptor
java.lang.Object
de.hybris.platform.ruleengine.dao.interceptors.RuleEngineRuleValidateInterceptor
- All Implemented Interfaces:
Interceptor,ValidateInterceptor<DroolsRuleModel>
public class RuleEngineRuleValidateInterceptor
extends Object
implements ValidateInterceptor<DroolsRuleModel>
AbstractRuleEngineRuleModel validation interceptor. Makes sure we do not save the model state, which could lead to
versioned instance inconsistency
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected L10NServiceprotected AbstractValidationResultgetValidationResult(DroolsRuleModel droolsRule, InterceptorContext ctx) protected RuleModelValidatorvoidonValidate(DroolsRuleModel droolsRule, InterceptorContext ctx) Called in themodelService.saveAll()method.voidsetL10NService(L10NService l10NService) voidsetValidator(RuleModelValidator validator)
-
Constructor Details
-
RuleEngineRuleValidateInterceptor
public RuleEngineRuleValidateInterceptor()
-
-
Method Details
-
onValidate
public void onValidate(DroolsRuleModel droolsRule, InterceptorContext ctx) throws InterceptorException Description copied from interface:ValidateInterceptorCalled in themodelService.saveAll()method. Validates the values of the given model.- Specified by:
onValidatein interfaceValidateInterceptor<DroolsRuleModel>- Parameters:
droolsRule- the model which values has to be validatedctx- theInterceptorContext- Throws:
InterceptorException- if any values of the model are not valid.
-
getValidationResult
protected AbstractValidationResult getValidationResult(DroolsRuleModel droolsRule, InterceptorContext ctx) -
getValidator
-
setValidator
-
getL10NService
-
setL10NService
-