Package nl.knaw.dans.lib.util.ruleengine
Interface RuleEngine
- All Known Implementing Classes:
RuleEngineImpl
public interface RuleEngine
Engine for validating bags against rule sets.
-
Method Summary
Modifier and TypeMethodDescriptionvalidateBag(Path bag, List<NumberedRule> rules) Validates the given bag against a given rule set.voidvalidateRuleSet(List<NumberedRule> rules) Check that a rule set is internally consistent.
-
Method Details
-
validateRuleSet
Check that a rule set is internally consistent. It checks for duplicate rules and for unresolved dependencies.- Parameters:
rules- the rule set- Throws:
RuleEngineConfigurationException- if the rule set is not consistent
-
validateBag
Validates the given bag against a given rule set.- Parameters:
bag- the bag to validaterules- the rule set- Returns:
- the validation result
- Throws:
Exception- if the validation could not be completed successfully
-