public class DroolsRuleValidateInterceptor extends java.lang.Object implements ValidateInterceptor<DroolsRuleModel>
false:
Check that DroolsRule.code doesn't contain double-quote (") and that @ruleCode meta-data is present
in DroolsRule.drl and matches DroolsRule.code:
droolsruleengineservices.validate.droolsrule.rulecode
Check that @moduleName meta-data is present
in DroolsRule.drl and matches AbstractRulesModule.name:
droolsruleengineservices.validate.droolsrule.rulecode
Check for DroolsRule.uuid doesn't contain double-quote(") and that it matches the DroolsRule.drl rule
declaration ( using double-quotes around the rule, e.g. rule "this is the rule uuid"):
droolsruleengineservices.validate.droolsrule.rulename
Check that DroolsRule.rulePackage attribute (if set) matches the package declaration in the
DroolsRule.drl content: droolsruleengineservices.validate.droolsrule.rulepackage| Constructor and Description |
|---|
DroolsRuleValidateInterceptor() |
public void onValidate(DroolsRuleModel model, InterceptorContext ctx) throws InterceptorException
ValidateInterceptormodelService.saveAll() method. Validates the values of the given model.onValidate in interface ValidateInterceptor<DroolsRuleModel>model - the model which values has to be validatedctx - the InterceptorContextInterceptorException - if any values of the model are not valid.protected java.util.List<DroolsRuleModel> getActiveRules(DroolsKIEBaseModel base)
protected void validateContentForRuleName(DroolsRuleModel model) throws InterceptorException
InterceptorExceptionprotected void validateContentForRulePackage(DroolsRuleModel model) throws InterceptorException
InterceptorExceptionprotected void validateContentForModuleName(DroolsRuleModel model) throws InterceptorException
InterceptorExceptionprotected void validateContentForRuleCode(DroolsRuleModel model) throws InterceptorException
InterceptorExceptionprotected void validateRuleName(DroolsRuleModel model) throws InterceptorException
InterceptorExceptionprotected void validateRuleCode(DroolsRuleModel model) throws InterceptorException
InterceptorExceptionprotected java.util.function.BiPredicate<DroolsRuleModel,DroolsRuleModel> getSameNameAndPackageBiPredicate()
public void setSameNameAndPackageBiPredicate(java.util.function.BiPredicate<DroolsRuleModel,DroolsRuleModel> sameNameAndPackageBiPredicate)
protected ConfigurationService getConfigurationService()
public void setConfigurationService(ConfigurationService configurationService)
protected EngineRuleDao getEngineRuleDao()
public void setEngineRuleDao(EngineRuleDao engineRuleDao)
Copyright © 2018 SAP SE. All Rights Reserved.