Interface | osid.rules.RulesSession | ||
---|---|---|---|
Implements | osid.OsidSession | ||
Description |
This session provides methods to evaluate and execute rules. | ||
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 | getConditionForRule | ||
Description |
Gets a condition for the given rule. | ||
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 | evaluateRule | ||
Description |
Evaluates a rule based on an input condition. | ||
Parameters | osid.id.Id | ruleId | a rule Id |
osid.rules.Condition | condition | input conditions | |
Return | boolean | result of the evaluation | |
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 not of this service | ||
Compliance | mandatory | This method must be implemented. | |
Method | executeRule | ||
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 not of this service | ||
Compliance | mandatory | This method must be implemented. |