| Interface | osid.rules.RuleEvaluationSession | ||
|---|---|---|---|
| Implements | osid.OsidSession | ||
| Used By | osid.rules.RulesManager | ||
osid.rules.RulesProxyManager | |||
| Description |
This session provides methods to evaluate and execute
rules. An | ||
| Method | getEngineId | ||
| Description |
Gets the | ||
| Return | osid.id.Id | the Engine Id associated with this session | |
| Compliance | mandatory | This method must be implemented. | |
| Method | getEngine | ||
| Description |
Gets the | ||
| Return | osid.rules.Engine | the engine | |
| Errors | OPERATION_FAILED | unable to complete request | |
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | canEvaluateRules | ||
| Description |
Tests if this user can evaluate rules. A return of true
does not guarantee successful authorization. A return of
false indicates that it is known all methods in this
session will result in a | ||
| Return | boolean | false if evaluation methods are not authorized,
true otherwise | |
| Compliance | mandatory | This method must be implemented. | |
| Method | getCondition | ||
| Description |
Gets a condition for the given rule. The record
| ||
| Parameters | osid.id.Id | ruleId | the Id of a Rule |
| Return | osid.rules.Condition | the returned Condition | |
| Errors | NOT_FOUND | no Rule found with the given Id | |
| NULL_ARGUMENT | ruleId is null | ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | evaluateRuleOnCondition | ||
| Description |
Evaluates a rule based on an input condition abd returns a boolean result. | ||
| Parameters | osid.id.Id | ruleId | a rule Id |
osid.rules.Condition | condition | input condition | |
| Return | boolean | result of the evaluation | |
| Errors | NOT_FOUND | ruleId is not found | |
| NULL_ARGUMENT | ruleId or condition is null | ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| UNSUPPORTED | condition did not otiginate from
getConditionForRule() | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | executeRuleOnCondition | ||
| Description |
Executes a rule based on an input condition and returns a result. | ||
| Parameters | osid.id.Id | ruleId | a rule Id |
osid.rules.Condition | condition | input conditions | |
| Return | osid.rules.Result | result of the execution | |
| Errors | NOT_FOUND | an Id was not found | |
| NULL_ARGUMENT | ruleId or condition is null | ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| UNSUPPORTED | condition did not otiginate from
getConditionForRule() | ||
| Compliance | mandatory | This method must be implemented. | |