OSID Logo
OSID Specifications
osid package
Version 3.1.0
Interfaceosid.OsidRuleApplicator
Implementsosid.OsidEnabler
Implemented Byosid.rules.check.Instruction
Description

An OsidRuleApplicator is an OsidEnabler used to evaluate the applicability of an OsidRule. An OsidRule is applicable when any OsidRuleApplicator is active and the applied data of the OsidEnabler fits within the evaluation context of the OsidRuleApplicatorCondition. Unlike other OsidEnablers, OsidRuleApplicators do not effect the active status of its OsidRules. Applicability is always determined through an evaluation.

If isRequirement() is true, then this OsidRuleApplicator must be active and applicable regardless of the state of any other OsidRuleApplicators mapped to the OsidRule.

OsidRuleApplicators define several built-in dimensions to govern its own operational status. In in active OsidRuleApplicator is never applicable in an OsidRule evaluation.
  • effective dates: The OsidEnabler is operational during these dates and evaluated using a date.
  • schedule: The OsidEnabler is operational when the date is occurs on the Schedule and the date is within the effective dates.
  • event: The OsidEnabler is operational when the date occurs within the Event and the date is within the effective dates. Events may be comprised of Schedules and other rules making them discontinuous.
  • cyclic event: The OsidEnabler is operational when the date cccurs within the CyclicEvent and the date is within the effective dates. CyclicEvents may be complex recurring events but also recur from one time period to the next, such as annually.
  • time period: The OsidEnabler is operational during a TimePeriod.
  • cyclic time period: The OsidEnabler is operational during a recurring TimePeriod. For example, any Spring term.
OsidRuleApplicators define several built-in application conditions to determine if an OsidRule is applicable in an evaluation.
  • applied time period: This time period to which this applies. OsidEnablers already include a time period to govern its operational status which is determined by the date range of the time period. However, this time period is used as a reporting time period determined by the context of the evaluation. For example, an OsidRule may be applied during a Spring Term for Fall Term Registration. "During Spring Term" is the operational status and "for Fall Term" is the contextual condition. The dates in applicable time periods typically do not matter.
  • applied cyclic time period: A recurring time period to which this applies.
  • applied resource: A single resource, group of resources, or demographic of resources to which this applies.
MethodisAppliedToTimePeriod
Description

Tests if applicability depends on a TimePeriod. A TimePeriod is effectively bounded by its effective dates which determine whether or not an OsidRule is applicable. For example, an OsidRule may be active between June 1 and June 30 but applied to financial transactions pertaining to 2015Q4.

Returnboolean true if the enabler applied to a time period, false otherwise
Compliancemandatory This method must be implemented.
MethodgetAppliedTimePeriodId
Description

Gets the time period Id.

Returnosid.id.Id the time period Id
ErrorsILLEGAL_STATE isAppliedToTimePeriod() is false
Compliancemandatory This method must be implemented.
MethodgetAppliedTimePeriod
Description

Gets the time period.

Returnosid.calendaring.TimePeriod the time period
ErrorsILLEGAL_STATE isAppliedToTimePeriod() is false
OPERATION_FAILED unable to complete request
Compliancemandatory This method must be implemented.
MethodisAppliedToCyclicTimePeriod
Description

Tests if applicability depends on a recurring CyclicTimePeriod. If a cyclic time period exists, it is effectively bounded by the effective dates of this enabler that determine whether or not an OsidRule is applicable.

Returnboolean true if the enabler is appleid to a cycic time period, false otherwise
Compliancemandatory This method must be implemented.
MethodgetAppliedCyclicTimePeriodId
Description

Gets the cyclic time period Id.

Returnosid.id.Id the cyclic time period Id
ErrorsILLEGAL_STATE isAppliedToCyclicTimePeriod() is false
Compliancemandatory This method must be implemented.
MethodgetAppliedCyclicTimePeriod
Description

Gets the cyclic time period.

Returnosid.calendaring.cycle.CyclicTimePeriod the cyclic time period
ErrorsILLEGAL_STATE isAppliedToCyclicTimePeriod() is false
OPERATION_FAILED unable to complete request
Compliancemandatory This method must be implemented.
MethodisAppliedToResource
Description

Tests if the applicability depends on a resource.

Returnboolean true if the rule applies to a resource, false otherwise
Compliancemandatory This method must be implemented.
MethodgetAppliedResourceId
Description

Gets the resource Id.

Returnosid.id.Id the resource Id
ErrorsILLEGAL_STATE isAppliedToResource() is false
Compliancemandatory This method must be implemented.
MethodgetAppliedResource
Description

Gets the resource.

Returnosid.resource.Resource the resource
ErrorsILLEGAL_STATE isAppliedToResource() is false
OPERATION_FAILED unable to complete request
Compliancemandatory This method must be implemented.