Interface LessonQuery

All Superinterfaces:
Extensible, OsidBrowsableQuery, OsidExtensibleQuery, OsidIdentifiableQuery, OsidObjectQuery, OsidQuery, OsidRelationshipQuery, OsidTemporalQuery, Suppliable

public interface LessonQuery extends OsidRelationshipQuery

This is the query for searching for lessons. Each method specifies an AND term while multiple invocations of the same method produce a nested OR .

  • Method Details

    • matchPlanId

      void matchPlanId(Id planId, boolean match)
      Sets the plan Id for this query.
      Parameters:
      planId - a plan Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - planId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearPlanIdTerms

      void clearPlanIdTerms()
      Clears the plan Id tems.
      Compliance:
      mandatory - This method must be implemented.
    • supportsPlanQuery

      boolean supportsPlanQuery()
      Tests if a plan query is available.
      Returns:
      true if a plan query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getPlanQuery

      PlanQuery getPlanQuery()
      Gets the query for a plan.
      Returns:
      the plan query
      Throws:
      UnimplementedException - supportsPlanQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsPlanQuery()} is {@code true} .
    • clearPlanTerms

      void clearPlanTerms()
      Clears the plan terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchDocetId

      void matchDocetId(Id docetId, boolean match)
      Sets the docet Id for this query.
      Parameters:
      docetId - a docet Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - docetId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearDocetIdTerms

      void clearDocetIdTerms()
      Clears the docet Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsDocetQuery

      boolean supportsDocetQuery()
      Tests if a docet query is available.
      Returns:
      true if a docet query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getDocetQuery

      DocetQuery getDocetQuery()
      Gets the query for a docet.
      Returns:
      the docet query
      Throws:
      UnimplementedException - supportsDocetQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsDocetQuery()} is {@code true} .
    • matchAnyDocet

      void matchAnyDocet(boolean match)
      Matches a lesson that has any docet.
      Parameters:
      match - true to match lessons with any docet, false to match lessons with no docet
      Compliance:
      mandatory - This method must be implemented.
    • clearDocetTerms

      void clearDocetTerms()
      Clears the docet terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchActivityId

      void matchActivityId(Id activitytId, boolean match)
      Sets the activity Id for this query.
      Parameters:
      activitytId - an activity Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - activityId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearActivityIdTerms

      void clearActivityIdTerms()
      Clears the activity Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsActivityQuery

      boolean supportsActivityQuery()
      Tests if an activity query is available.
      Returns:
      true if an activity query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getActivityQuery

      ActivityQuery getActivityQuery()
      Gets the query for an activity.
      Returns:
      the activity query
      Throws:
      UnimplementedException - supportsActivityQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsActivityQuery()} is {@code true} .
    • matchAnyActivity

      void matchAnyActivity(boolean match)
      Matches a lesson that has any activity.
      Parameters:
      match - true to match lessons with any activity, false to match lessons with no activities
      Compliance:
      mandatory - This method must be implemented.
    • clearActivityTerms

      void clearActivityTerms()
      Clears the activity terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchPlannedStartTime

      void matchPlannedStartTime(Duration from, Duration to, boolean match)
      Matches a planned start time within the given duration range inclusive.
      Parameters:
      from - a starting date
      to - an ending date
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - from or to is null
      Compliance:
      mandatory - This method must be implemented.
    • matchAnyPlannedStartTime

      void matchAnyPlannedStartTime(boolean match)
      Matches a lesson that has any planned start time.
      Parameters:
      match - true to match lessons with any planned start time, false to match lessons with no planned start time
      Compliance:
      mandatory - This method must be implemented.
    • clearPlannedStartTimeTerms

      void clearPlannedStartTimeTerms()
      Clears the planned start time terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchActualStartTime

      void matchActualStartTime(Duration from, Duration to, boolean match)
      Matches an actual start time within the given date range inclusive.
      Parameters:
      from - a starting date
      to - an ending date
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - from or to is null
      Compliance:
      mandatory - This method must be implemented.
    • matchAnyActualStartTime

      void matchAnyActualStartTime(boolean match)
      Matches a lesson that has begun.
      Parameters:
      match - true to match lessons with any actual start time, false to match lessons with no actual start time
      Compliance:
      mandatory - This method must be implemented.
    • clearActualStartTimeTerms

      void clearActualStartTimeTerms()
      Clears the actual start time terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchActualStartingActivityId

      void matchActualStartingActivityId(Id activitytId, boolean match)
      Sets the starting activity Id for this query.
      Parameters:
      activitytId - an activity Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - activityId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearActualStartingActivityIdTerms

      void clearActualStartingActivityIdTerms()
      Clears the starting activity Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsActualStartingActivityQuery

      boolean supportsActualStartingActivityQuery()
      Tests if a starting activity query is available.
      Returns:
      true if a starting activity query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getActualStartingActivityQuery

      ActivityQuery getActualStartingActivityQuery()
      Gets the query for a starting activity.
      Returns:
      the activity query
      Throws:
      UnimplementedException - supportsActualStartingActivityQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsActualStartingActivityQuery()} is {@code true} .
    • matchAnyActualStartingActivity

      void matchAnyActualStartingActivity(boolean match)
      Matches a lesson that has any starting activity.
      Parameters:
      match - true to match lessons with any starting activity, false to match lessons with no starting activity
      Compliance:
      mandatory - This method must be implemented.
    • clearActualStartingActivityTerms

      void clearActualStartingActivityTerms()
      Clears the starting activity terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchComplete

      void matchComplete(boolean match)
      Matches a lesson that has been completed.
      Parameters:
      match - true to match lessons that have been completed, false to match lessons that have not been completed
      Compliance:
      mandatory - This method must be implemented.
    • clearCompleteTerms

      void clearCompleteTerms()
      Clears the complete terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchSkipped

      void matchSkipped(boolean match)
      Matches a lesson that has been skipped.
      Parameters:
      match - true to match lessons that have been skipped, false to match lessons that have not been skipped
      Compliance:
      mandatory - This method must be implemented.
    • clearSkippedTerms

      void clearSkippedTerms()
      Clears the skipped terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchActualEndTime

      void matchActualEndTime(Duration from, Duration to, boolean match)
      Matches an actual ending time within the given date range inclusive.
      Parameters:
      from - a starting date
      to - an ending date
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - from or to is null
      Compliance:
      mandatory - This method must be implemented.
    • matchAnyActualEndTime

      void matchAnyActualEndTime(boolean match)
      Matches a lesson that has any actual end time.
      Parameters:
      match - true to match lessons with any actual end time, false to match lessons with no actual end time
      Compliance:
      mandatory - This method must be implemented.
    • clearActualEndTimeTerms

      void clearActualEndTimeTerms()
      Clears the actual end time terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchActualEndingActivityId

      void matchActualEndingActivityId(Id activitytId, boolean match)
      Sets the ending activity Id for this query.
      Parameters:
      activitytId - an activity Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - activityId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearActualEndingActivityIdTerms

      void clearActualEndingActivityIdTerms()
      Clears the ending activity Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsActualEndingActivityQuery

      boolean supportsActualEndingActivityQuery()
      Tests if an ending activity query is available.
      Returns:
      true if an ending activity query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getActualEndingActivityQuery

      ActivityQuery getActualEndingActivityQuery()
      Gets the query for an ending activity.
      Returns:
      the activity query
      Throws:
      UnimplementedException - supportsEndingActivityQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsEndingActivityQuery()} is {@code true} .
    • matchAnyActualEndingActivity

      void matchAnyActualEndingActivity(boolean match)
      Matches a lesson that has any ending activity.
      Parameters:
      match - true to match lessons with any ending activity, false to match lessons with no ending activity
      Compliance:
      mandatory - This method must be implemented.
    • clearActualEndingActivityTerms

      void clearActualEndingActivityTerms()
      Clears the ending activity terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchActualTimeSpent

      void matchActualTimeSpent(Duration from, Duration to, boolean match)
      Matches an actual time spent within the given duration range inclusive.
      Parameters:
      from - a starting date
      to - an ending date
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - from or to is null
      Compliance:
      mandatory - This method must be implemented.
    • matchAnyActualTimeSpent

      void matchAnyActualTimeSpent(boolean match)
      Matches a lesson that has any actual time spent.
      Parameters:
      match - true to match lessons with any actual time spent, false to match lessons with no time spent
      Compliance:
      mandatory - This method must be implemented.
    • clearActualTimeSpentTerms

      void clearActualTimeSpentTerms()
      Clears the actual time spent terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchCourseCatalogId

      void matchCourseCatalogId(Id courseCatalogId, boolean match)
      Sets the lesson Id for this query to match syllabi assigned to course catalogs.
      Parameters:
      courseCatalogId - a course catalog Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - courseCatalogId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearCourseCatalogIdTerms

      void clearCourseCatalogIdTerms()
      Clears the course catalog Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsCourseCatalogQuery

      boolean supportsCourseCatalogQuery()
      Tests if an CourseCatalogQuery is available.
      Returns:
      true if a course catalog query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getCourseCatalogQuery

      CourseCatalogQuery getCourseCatalogQuery()
      Gets the query for a course catalog query. Multiple retrievals produce a nested OR term.
      Returns:
      the course catalog query
      Throws:
      UnimplementedException - supportsCourseCatalogQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsCourseCatalogQuery()} is {@code true} .
    • clearCourseCatalogTerms

      void clearCourseCatalogTerms()
      Clears the course catalog terms.
      Compliance:
      mandatory - This method must be implemented.
    • getLessonQueryRecord

      LessonQueryRecord getLessonQueryRecord(Type lessonRecordType) throws OperationFailedException
      Gets the lesson query record corresponding to the given Lesson record Type .Multiple record retrievals produce a nested boolean OR term.
      Parameters:
      lessonRecordType - a lesson record type
      Returns:
      the lesson query record
      Throws:
      NullArgumentException - lessonRecordType is null
      OperationFailedException - unable to complete request
      UnsupportedException - hasRecordType(lessonRecordType) is false
      Compliance:
      mandatory - This method must be implemented.