Interface CourseQuery

All Superinterfaces:
Extensible, OsidBrowsableQuery, OsidExtensibleQuery, OsidIdentifiableQuery, OsidObjectQuery, OsidOperableQuery, OsidQuery, Suppliable

public interface CourseQuery extends OsidObjectQuery, OsidOperableQuery

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

  • Method Details

    • matchTitle

      void matchTitle(String title, Type stringMatchType, boolean match)
      Adds a title for this query.
      Parameters:
      title - title string to match
      stringMatchType - the string match type
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - title not of stringMatchType
      NullArgumentException - title or stringMatchType is null
      UnsupportedException - supportsStringMatchType(stringMatchType) is false
      Compliance:
      mandatory - This method must be implemented.
    • matchAnyTitle

      void matchAnyTitle(boolean match)
      Matches a title that has any value.
      Parameters:
      match - true to match courses with any title, false to match courses with no title
      Compliance:
      mandatory - This method must be implemented.
    • clearTitleTerms

      void clearTitleTerms()
      Clears the title terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchNumber

      void matchNumber(String number, Type stringMatchType, boolean match)
      Adds a course number for this query.
      Parameters:
      number - course number string to match
      stringMatchType - the string match type
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - number not of stringMatchType
      NullArgumentException - number or stringMatchType is null
      UnsupportedException - supportsStringMatchType(stringMatchType) is false
      Compliance:
      mandatory - This method must be implemented.
    • matchAnyNumber

      void matchAnyNumber(boolean match)
      Matches a course number that has any value.
      Parameters:
      match - true to match courses with any number, false to match courses with no title
      Compliance:
      mandatory - This method must be implemented.
    • clearNumberTerms

      void clearNumberTerms()
      Clears the number terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchSponsorId

      void matchSponsorId(Id resourceId, boolean match)
      Sets the resource Id for this query to match courses that have a sponsor.
      Parameters:
      resourceId - a resource Id
      match - true if a positive match, false for a negative match
      Throws:
      NullArgumentException - resourceId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearSponsorIdTerms

      void clearSponsorIdTerms()
      Clears the sponsor Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsSponsorQuery

      boolean supportsSponsorQuery()
      Tests if a ResourceQuery is available.
      Returns:
      true if a resource query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getSponsorQuery

      ResourceQuery getSponsorQuery()
      Gets the query for a sponsor. Multiple retrievals produce a nested OR term.
      Returns:
      a resource query
      Throws:
      UnimplementedException - supportsSponsorQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsSponsorQuery()} is {@code true} .
    • matchAnySponsor

      void matchAnySponsor(boolean match)
      Matches courses that have any sponsor.
      Parameters:
      match - true to match courses with any sponsor, false to match courses with no sponsors
      Compliance:
      mandatory - This method must be implemented.
    • clearSponsorTerms

      void clearSponsorTerms()
      Clears the sponsor terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchCreditAmountId

      void matchCreditAmountId(Id gradeId, boolean match)
      Sets the grade Id for this query to match courses with a credit amount.
      Parameters:
      gradeId - a grade Id
      match - true if a positive match, false for a negative match
      Throws:
      NullArgumentException - gradeId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearCreditAmountIdTerms

      void clearCreditAmountIdTerms()
      Clears the grade system Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsCreditAmountQuery

      boolean supportsCreditAmountQuery()
      Tests if a GradeQuery is available.
      Returns:
      true if a grade system query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getCreditAmountQuery

      GradeQuery getCreditAmountQuery()
      Gets the query for a credit amount. Multiple retrievals produce a nested OR term.
      Returns:
      a grade query
      Throws:
      UnimplementedException - supportsCreditQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsCreditQuery()} is {@code true} .
    • matchAnyCreditAmount

      void matchAnyCreditAmount(boolean match)
      Matches courses that have any credits.
      Parameters:
      match - true to match courses with any credits false to match courses with no credits
      Compliance:
      mandatory - This method must be implemented.
    • clearCreditAmountTerms

      void clearCreditAmountTerms()
      Clears the credit terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchPrerequisitesInfo

      void matchPrerequisitesInfo(String prereqInfo, Type stringMatchType, boolean match)
      Matches courses with the prerequisites informational string.
      Parameters:
      prereqInfo - prerequisite informational string to match
      stringMatchType - the string match type
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - prereqInfo not of stringMatchType
      NullArgumentException - prereqInfo or stringMatchType is null
      UnsupportedException - supportsStringMatchType(stringMatchType) is false
      Compliance:
      mandatory - This method must be implemented.
    • matchAnyPrerequisitesInfo

      void matchAnyPrerequisitesInfo(boolean match)
      Matches a course that has any prerequisite information assigned.
      Parameters:
      match - true to match courses with any prerequisite information, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • clearPrerequisitesInfoTerms

      void clearPrerequisitesInfoTerms()
      Clears the prerequisite info terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchPrerequisitesId

      void matchPrerequisitesId(Id requisiteId, boolean match)
      Sets the requisite Id for this query.
      Parameters:
      requisiteId - a requisite Id
      match - true if a positive match, false for a negative match
      Throws:
      NullArgumentException - requisiteId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearPrerequisitesIdTerms

      void clearPrerequisitesIdTerms()
      Clears the requisite Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsPrerequisitesQuery

      boolean supportsPrerequisitesQuery()
      Tests if a RequisiteQuery is available.
      Returns:
      true if a requisite query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getPrerequisitesQuery

      RequisiteQuery getPrerequisitesQuery()
      Gets the query for a requisite. Multiple retrievals produce a nested OR term.
      Returns:
      a prerequisites query
      Throws:
      UnimplementedException - supportsPrerequisitesQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsPrerequisitesQuery()} is {@code true} .
    • matchAnyPrerequisites

      void matchAnyPrerequisites(boolean match)
      Matches courses that have any prerequisites.
      Parameters:
      match - true to match courses with any prerequisites, false to match courses with no prerequisites
      Compliance:
      mandatory - This method must be implemented.
    • clearPrerequisitesTerms

      void clearPrerequisitesTerms()
      Clears the prerequisites terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchConcurrentCourseId

      void matchConcurrentCourseId(Id courseId, boolean match)
      Sets the concurrent course Id for this query.
      Parameters:
      courseId - a course Id
      match - true if a positive match, false for a negative match
      Throws:
      NullArgumentException - courseId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearConcurrentCourseIdTerms

      void clearConcurrentCourseIdTerms()
      Clears the concurrent course Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsConcurrentCourseQuery

      boolean supportsConcurrentCourseQuery()
      Tests if a CourseQuery is available.
      Returns:
      true if a course query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getConcurrentCourseQuery

      CourseQuery getConcurrentCourseQuery()
      Gets the query for a concurrent course. Multiple retrievals produce a nested OR term.
      Returns:
      a course query
      Throws:
      UnimplementedException - supportsConcurrentCourseQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsConcurrentCourseQuery()} is {@code true} .
    • matchAnyConcurrentCourse

      void matchAnyConcurrentCourse(boolean match)
      Matches courses that have any concurrent courses.
      Parameters:
      match - true to match courses with any concurrent courses, false to match courses with no concurrent courses
      Compliance:
      mandatory - This method must be implemented.
    • clearConcurrentCourseTerms

      void clearConcurrentCourseTerms()
      Clears the concurrent course terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchLevelId

      void matchLevelId(Id gradeId, boolean match)
      Sets the grade Id for this query.
      Parameters:
      gradeId - a grade Id
      match - true if a positive match, false for a negative match
      Throws:
      NullArgumentException - gradeId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearLevelIdTerms

      void clearLevelIdTerms()
      Clears the grade Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsLevelQuery

      boolean supportsLevelQuery()
      Tests if a GradeQuery is available.
      Returns:
      true if a grade query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getLevelQuery

      GradeQuery getLevelQuery()
      Gets the query for a grade level. Multiple retrievals produce a nested OR term.
      Returns:
      a grade query
      Throws:
      UnimplementedException - supportsLevelQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsLevelQuery()} is {@code true} .
    • matchAnyLevel

      void matchAnyLevel(boolean match)
      Matches courses that have any grade level.
      Parameters:
      match - true to match courses with any level, false to match courses with no level
      Compliance:
      mandatory - This method must be implemented.
    • clearLevelTerms

      void clearLevelTerms()
      Clears the level terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchGradingOptionId

      void matchGradingOptionId(Id gradeSystemId, boolean match)
      Sets the grade system Id for this query.
      Parameters:
      gradeSystemId - a grade system Id
      match - true if a positive match, false for a negative match
      Throws:
      NullArgumentException - gradeSystemId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearGradingOptionIdTerms

      void clearGradingOptionIdTerms()
      Clears the grade system Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsGradingOptionQuery

      boolean supportsGradingOptionQuery()
      Tests if a GradeSystemQuery is available.
      Returns:
      true if a grade system query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getGradingOptionQuery

      GradeSystemQuery getGradingOptionQuery()
      Gets the query for a grading option. Multiple retrievals produce a nested OR term.
      Returns:
      a grade system query
      Throws:
      UnimplementedException - supportsGradingOptionQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsGradingOptionQuery()} is {@code true} .
    • matchAnyGradingOption

      void matchAnyGradingOption(boolean match)
      Matches courses that have any grading option.
      Parameters:
      match - true to match courses with any grading option, false to match courses with no grading options
      Compliance:
      mandatory - This method must be implemented.
    • clearGradingOptionTerms

      void clearGradingOptionTerms()
      Clears the grading option terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchLearningObjectiveId

      void matchLearningObjectiveId(Id objectiveId, boolean match)
      Sets the objective Id for this query.
      Parameters:
      objectiveId - an objective Id
      match - true if a positive match, false for a negative match
      Throws:
      NullArgumentException - objectiveId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearLearningObjectiveIdTerms

      void clearLearningObjectiveIdTerms()
      Clears the objective Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsLearningObjectiveQuery

      boolean supportsLearningObjectiveQuery()
      Tests if a ObjectiveQuery is available.
      Returns:
      true if an objective query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getLearningObjectiveQuery

      ObjectiveQuery getLearningObjectiveQuery()
      Gets the query for a learning objective. Multiple retrievals produce a nested OR term.
      Returns:
      an objective query
      Throws:
      UnimplementedException - supportsLearningObjectiveQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsLearningObjectiveQuery()} is {@code true} .
    • matchAnyLearningObjective

      void matchAnyLearningObjective(boolean match)
      Matches courses that have any learning objective.
      Parameters:
      match - true to match courses with any learning objective, false to match courses with no learning objectives
      Compliance:
      mandatory - This method must be implemented.
    • clearLearningObjectiveTerms

      void clearLearningObjectiveTerms()
      Clears the learning objective terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchTargetAudienceId

      void matchTargetAudienceId(Id resourceId, boolean match)
      Sets the resource Id for this query to match courses that have a target audience.
      Parameters:
      resourceId - a resource Id
      match - true if a positive match, false for a negative match
      Throws:
      NullArgumentException - resourceId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearTargetAudienceIdTerms

      void clearTargetAudienceIdTerms()
      Clears the target audience Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsTargetAudienceQuery

      boolean supportsTargetAudienceQuery()
      Tests if a ResourceQuery is available.
      Returns:
      true if a resource query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getTargetAudienceQuery

      ResourceQuery getTargetAudienceQuery()
      Gets the query for a target audience. Multiple retrievals produce a nested OR term.
      Returns:
      a resource query
      Throws:
      UnimplementedException - supportsTargetAudienceQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsTargetAudienceQuery()} is {@code true} .
    • matchAnyTargetAudience

      void matchAnyTargetAudience(boolean match)
      Matches courses that have any target audience.
      Parameters:
      match - true to match courses with any target audience, false to match courses with no target audiences
      Compliance:
      mandatory - This method must be implemented.
    • clearTargetAudienceTerms

      void clearTargetAudienceTerms()
      Clears the target audience terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchActivityUnitId

      void matchActivityUnitId(Id courseOfferingId, boolean match)
      Sets the course offering Id for this query to match courses that have a related course offering.
      Parameters:
      courseOfferingId - a course offering Id
      match - true if a positive match, false for a negative match
      Throws:
      NullArgumentException - courseOfferingId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearActivityUnitIdTerms

      void clearActivityUnitIdTerms()
      Clears the activity unit Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsActivityUnitQuery

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

      ActivityUnitQuery getActivityUnitQuery()
      Gets the query for an activity unit. Multiple retrievals produce a nested OR term.
      Returns:
      the activity unit query
      Throws:
      UnimplementedException - supportsActivityUnitQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsActivityUnitQuery()} is {@code true} .
    • matchAnyActivityUnit

      void matchAnyActivityUnit(boolean match)
      Matches courses that have any course offering.
      Parameters:
      match - true to match courses with any related activity unit, false to match courses with no activity units
      Compliance:
      mandatory - This method must be implemented.
    • clearActivityUnitTerms

      void clearActivityUnitTerms()
      Clears the activity unit terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchCourseOfferingId

      void matchCourseOfferingId(Id courseOfferingId, boolean match)
      Sets the course offering Id for this query to match courses that have a related course offering.
      Parameters:
      courseOfferingId - a course offering Id
      match - true if a positive match, false for a negative match
      Throws:
      NullArgumentException - courseOfferingId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearCourseOfferingIdTerms

      void clearCourseOfferingIdTerms()
      Clears the course offering Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsCourseOfferingQuery

      boolean supportsCourseOfferingQuery()
      Tests if a CourseOfferingQuery is available.
      Returns:
      true if a course offering query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getCourseOfferingQuery

      CourseOfferingQuery getCourseOfferingQuery()
      Gets the query for a course offering. Multiple retrievals produce a nested OR term.
      Returns:
      the course offering query
      Throws:
      UnimplementedException - supportsCourseOfferingQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsCourseOfferingQuery()} is {@code true} .
    • matchAnyCourseOffering

      void matchAnyCourseOffering(boolean match)
      Matches courses that have any course offering.
      Parameters:
      match - true to match courses with any course offering, false to match courses with no course offering
      Compliance:
      mandatory - This method must be implemented.
    • clearCourseOfferingTerms

      void clearCourseOfferingTerms()
      Clears the course offering terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchCourseCatalogId

      void matchCourseCatalogId(Id courseCatalogId, boolean match)
      Sets the course catalog Id for this query to match courses assigned to course catalogs.
      Parameters:
      courseCatalogId - the 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 a 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. 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.
    • getCourseQueryRecord

      CourseQueryRecord getCourseQueryRecord(Type courseRecordType) throws OperationFailedException
      Gets the course query record corresponding to the given Course record Type .Multiple record retrievals produce a nested OR term.
      Parameters:
      courseRecordType - a course record type
      Returns:
      the course query record
      Throws:
      NullArgumentException - courseRecordType is null
      OperationFailedException - unable to complete request
      UnsupportedException - hasRecordType(courseRecordType) is false
      Compliance:
      mandatory - This method must be implemented.