Class CurrentNodeFunctionDecorator
java.lang.Object
ch.tocco.nice2.optional.qualification.impl.drools.rules.decorators.CurrentNodeFunctionDecorator
- All Implemented Interfaces:
CustomRuleDecorator
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionorg.kie.api.io.Resource
decorate
(org.kie.api.io.Resource resource, RuleSource source, String packageName) Decorate a custom rule.int
priority()
add functions beforeDrlHeaderCustomRuleDecorator
adds package name at the top
-
Field Details
-
NODE_NAME_CONTEXT
- See Also:
-
NODE_KEY_CONTEXT
- See Also:
-
NODE_META_DATA_TAG
- See Also:
-
-
Constructor Details
-
CurrentNodeFunctionDecorator
public CurrentNodeFunctionDecorator()
-
-
Method Details
-
decorate
public org.kie.api.io.Resource decorate(org.kie.api.io.Resource resource, RuleSource source, String packageName) throws IOException Description copied from interface:CustomRuleDecorator
Decorate a custom rule.- Specified by:
decorate
in interfaceCustomRuleDecorator
- 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
public int priority()add functions beforeDrlHeaderCustomRuleDecorator
adds package name at the top- Specified by:
priority
in interfaceCustomRuleDecorator
-