Interface AssessmentPartQuery

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

public interface AssessmentPartQuery extends OsidObjectQuery, OsidContainableQuery, OsidOperableQuery

This is the query for searching assessment parts. Each method match request produces an AND term while multiple invocations of a method produces a nested OR .

  • Method Details

    • matchAssessmentId

      void matchAssessmentId(Id assessmentId, boolean match)
      Sets the assessment Id for this query.
      Parameters:
      assessmentId - an assessment Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - assessmentId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearAssessmentIdTerms

      void clearAssessmentIdTerms()
      Clears all assessment Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsAssessmentQuery

      boolean supportsAssessmentQuery()
      Tests if an AssessmentQuery is available.
      Returns:
      true if an assessment query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getAssessmentQuery

      AssessmentQuery getAssessmentQuery()
      Gets the query for an assessment. Multiple retrievals produce a nested OR term.
      Returns:
      the assessment query
      Throws:
      UnimplementedException - supportsAssessmentQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsAssessmentQuery()} is {@code true} .
    • clearAssessmentTerms

      void clearAssessmentTerms()
      Clears all assessment terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchParentAssessmentPartId

      void matchParentAssessmentPartId(Id assessmentPartId, boolean match)
      Sets the assessment part Id for this query.
      Parameters:
      assessmentPartId - an assessment part Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - assessmentPartId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearParentAssessmentPartIdTerms

      void clearParentAssessmentPartIdTerms()
      Clears all assessment part Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsParentAssessmentPartQuery

      boolean supportsParentAssessmentPartQuery()
      Tests if an AssessmentPartQuery is available.
      Returns:
      true if an assessment part query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getParentAssessmentPartQuery

      AssessmentPartQuery getParentAssessmentPartQuery()
      Gets the query for an assessment part. Multiple retrievals produce a nested OR term.
      Returns:
      the assessment part query
      Throws:
      UnimplementedException - supportsParentAssessmentPartQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsParentAssessmentPartQuery()} is {@code true} .
    • matchAnyParentAssessmentPart

      void matchAnyParentAssessmentPart(boolean match)
      Matches assessment parts with any parent assessment part.
      Parameters:
      match - true to match assessment parts with any parent, false to match assessment parts with no parents
      Compliance:
      mandatory - This method must be implemented.
    • clearParentAssessmentPartTerms

      void clearParentAssessmentPartTerms()
      Clears all assessment part terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchSection

      void matchSection(boolean match)
      Matches assessment parts that are also used as sections.
      Parameters:
      match - true for a positive match, false for a negative match
      Compliance:
      mandatory - This method must be implemented.
    • clearSectionTerms

      void clearSectionTerms()
      Clears all section terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchWeight

      void matchWeight(long low, long high, boolean match)
      Matches assessment parts that fall in between the given weights inclusive.
      Parameters:
      low - low end of range
      high - high end of range
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - high is less than low
      Compliance:
      mandatory - This method must be implemented.
    • matchAnyWeight

      void matchAnyWeight(boolean match)
      Matches assessment parts with any weight assigned.
      Parameters:
      match - true to match assessment parts with any wieght, false to match assessment parts with no weight
      Compliance:
      mandatory - This method must be implemented.
    • clearWeightTerms

      void clearWeightTerms()
      Clears all weight terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchAllocatedTime

      void matchAllocatedTime(Duration low, Duration high, boolean match)
      Matches assessment parts hose allocated time falls in between the given times inclusive.
      Parameters:
      low - low end of range
      high - high end of range
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - high is less than low
      Compliance:
      mandatory - This method must be implemented.
    • matchAnyAllocatedTime

      void matchAnyAllocatedTime(boolean match)
      Matches assessment parts with any time assigned.
      Parameters:
      match - true to match assessment parts with any alloocated time, false to match assessment parts with no allocated time
      Compliance:
      mandatory - This method must be implemented.
    • clearAllocatedTimeTerms

      void clearAllocatedTimeTerms()
      Clears all allocated time terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchChildAssessmentPartId

      void matchChildAssessmentPartId(Id assessmentPartId, boolean match)
      Sets the assessment part Id for this query.
      Parameters:
      assessmentPartId - an assessment part Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - assessmentPartId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearChildAssessmentPartIdTerms

      void clearChildAssessmentPartIdTerms()
      Clears all assessment part Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsChildAssessmentPartQuery

      boolean supportsChildAssessmentPartQuery()
      Tests if an AssessmentPartQuery is available.
      Returns:
      true if an assessment part query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getChildAssessmentPartQuery

      AssessmentPartQuery getChildAssessmentPartQuery()
      Gets the query for an assessment part. Multiple retrievals produce a nested OR term.
      Returns:
      the assessment part query
      Throws:
      UnimplementedException - supportsChildAssessmentPartQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsChildAssessmentPartQuery()} is {@code true} .
    • matchAnyChildAssessmentPart

      void matchAnyChildAssessmentPart(boolean match)
      Matches assessment parts with any child assessment part.
      Parameters:
      match - true to match assessment parts with any children, false to match assessment parts with no children
      Compliance:
      mandatory - This method must be implemented.
    • clearChildAssessmentPartTerms

      void clearChildAssessmentPartTerms()
      Clears all assessment part terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchBankId

      void matchBankId(Id bankId, boolean match)
      Matches constrainers mapped to the bank.
      Parameters:
      bankId - the bank Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - bankId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearBankIdTerms

      void clearBankIdTerms()
      Clears the bank Id query terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsBankQuery

      boolean supportsBankQuery()
      Tests if an BankQuery is available.
      Returns:
      true if a bank query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getBankQuery

      BankQuery getBankQuery()
      Gets the query for a bank. Multiple retrievals produce a nested OR term.
      Returns:
      the bank query
      Throws:
      UnimplementedException - supportsBankQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsBankQuery()} is {@code true} .
    • clearBankTerms

      void clearBankTerms()
      Clears the bank query terms.
      Compliance:
      mandatory - This method must be implemented.
    • getAssessmentPartQueryRecord

      AssessmentPartQueryRecord getAssessmentPartQueryRecord(Type assessmentPartRecordType) throws OperationFailedException
      Gets the assessment part query record corresponding to the given AssessmentPart record Type . Multiple retrievals produce a nested OR term.
      Parameters:
      assessmentPartRecordType - an assessment part record type
      Returns:
      the assessment part query record
      Throws:
      NullArgumentException - assessmentPartRecordType is null
      OperationFailedException - unable to complete request
      UnsupportedException - hasRecordType(assessmentPartRecordType) is false
      Compliance:
      mandatory - This method must be implemented.