Interface CustomRuleDecorator
- All Known Implementing Classes:
CurrentNodeFunctionDecorator
,DrlHeaderCustomRuleDecorator
,TargetPathDecorator
public interface CustomRuleDecorator
A decorator for custom rules. This may be used to transform or complement custom rules,
e.g. add a package statement. A typical example for such a decorator is the
DrlHeaderCustomRuleDecorator
.- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionorg.kie.api.io.Resource
decorate
(org.kie.api.io.Resource resource, RuleSource source, String packageName) Decorate a custom rule.default int
priority()
-
Method Details
-
decorate
org.kie.api.io.Resource decorate(org.kie.api.io.Resource resource, RuleSource source, String packageName) throws IOException Decorate a custom rule.- Parameters:
resource
- The Drools `Resource` that is being loaded.source
- TheRuleSource
the rules are being loaded from.packageName
- A package name to be used for the rules.- Returns:
- A Drools `Resource` for the decorated custom rules.
- Throws:
IOException
- If an I/O error occurs.
-
priority
default int priority()
-