Interface OsidRuleApplicator

All Superinterfaces:
Browsable, Extensible, Identifiable, Operable, OsidEnabler, OsidObject, OsidRule, Temporal
All Known Subinterfaces:
Instruction

public interface OsidRuleApplicator extends OsidEnabler

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.
  • Method Details

    • isAppliedToTimePeriod

      boolean isAppliedToTimePeriod()
      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.
      Returns:
      true if the enabler applied to a time period, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getAppliedTimePeriodId

      Id getAppliedTimePeriodId()
      Gets the time period Id .
      Returns:
      the time period Id
      Throws:
      IllegalStateException - isAppliedToTimePeriod() is false
      Compliance:
      mandatory - This method must be implemented.
    • getAppliedTimePeriod

      TimePeriod getAppliedTimePeriod() throws OperationFailedException
      Gets the time period.
      Returns:
      the time period
      Throws:
      IllegalStateException - isAppliedToTimePeriod() is false
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • isAppliedToCyclicTimePeriod

      boolean isAppliedToCyclicTimePeriod()
      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.
      Returns:
      true if the enabler is appleid to a cycic time period, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getAppliedCyclicTimePeriodId

      Id getAppliedCyclicTimePeriodId()
      Gets the cyclic time period Id .
      Returns:
      the cyclic time period Id
      Throws:
      IllegalStateException - isAppliedToCyclicTimePeriod() is false
      Compliance:
      mandatory - This method must be implemented.
    • getAppliedCyclicTimePeriod

      CyclicTimePeriod getAppliedCyclicTimePeriod() throws OperationFailedException
      Gets the cyclic time period.
      Returns:
      the cyclic time period
      Throws:
      IllegalStateException - isAppliedToCyclicTimePeriod() is false
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • isAppliedToResource

      boolean isAppliedToResource()
      Tests if the applicability depends on a resource.
      Returns:
      true if the rule applies to a resource, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getAppliedResourceId

      Id getAppliedResourceId()
      Gets the resource Id .
      Returns:
      the resource Id
      Throws:
      IllegalStateException - isAppliedToResource() is false
      Compliance:
      mandatory - This method must be implemented.
    • getAppliedResource

      Resource getAppliedResource() throws OperationFailedException
      Gets the resource.
      Returns:
      the resource
      Throws:
      IllegalStateException - isAppliedToResource() is false
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.