
Rulesets
Rulesets serve as containers for Rules, and they are associated with Functions. A single BRFplus Function can have one or more Rulesets assigned to it, and the same Ruleset can be linked to multiple Functions. When a Function is called, it executes all the assigned Rulesets in the order they are linked.
When assigning multiple Rulesets to a Function, the execution order must be specified. It's essential to ensure that the Ruleset's context remains consistent. Variables used for calculations and validations within the Rules must be available in the Ruleset context. Rulesets inherit their context from the Function(s) to which they are assigned. Therefore, Rules within a Ruleset can perform actions like calculations and validations on variables found in the Function context. Any additional or helper variables used for intermediate calculations must be defined within the Ruleset context as ruleset variable separately.
Rules
Rules are the fundamental components of Rulesets, responsible for executing operations and calculations on the input data of BRFplus applications. They can trigger actions or modify the Result dataset based on specific process requirements. In BRFplus, a rule represents a simple business rule for a particular business case. Rules can adapt to increasing business case complexity by adding actions or expressions, and they can be combined into Rulesets. Rules can only be triggered within the context of a Ruleset to which they are assigned; they cannot be triggered independently.
The rule has the following features:
- A Rule comprises an If condition that the system evaluates when the rule is triggered. Depending on the condition's result, the rule performs a set of operations. The condition must include a True branch, while the False branch is optional.
- Rule execution can be contingent on various conditions such as rule enablement, time dependencies, and more. These additional conditions can be controlled within the context of the Rulesets to which a rule is linked.
- Within a Rule, you can access and manipulate context data. Accessing context data from a rule means utilizing the context data available to the rule through the associated Ruleset.
- A single rule can be assigned to multiple Rulesets. Consequently, the system grants the rule access only to context data objects shared by all referencing Rulesets. This ensures consistency.
Supported Operation Types for Rules
- Triggering an action.
- Processing an expression, with the expression's result potentially updating the context.
- Initializing or updating context data objects.








