Interface CalendarQuery

All Superinterfaces:
Extensible, OsidBrowsableQuery, OsidCatalogQuery, OsidExtensibleQuery, OsidFederateableQuery, OsidIdentifiableQuery, OsidObjectQuery, OsidQuery, OsidSourceableQuery, Suppliable

public interface CalendarQuery extends OsidCatalogQuery

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

  • Method Details

    • matchEventId

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

      void clearEventIdTerms()
      Clears the event Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsEventQuery

      boolean supportsEventQuery()
      Tests if an EventQuery is available.
      Returns:
      true if an event query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getEventQuery

      EventQuery getEventQuery()
      Gets the query for an event. Multiple retrievals produce a nested OR term.
      Returns:
      the event query
      Throws:
      UnimplementedException - supportsEventQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsEventQuery()} is {@code true} .
    • matchAnyEvent

      void matchAnyEvent(boolean match)
      Matches a calendar that has any event assigned.
      Parameters:
      match - true to match calendars with any event, false to match calendars with no events
      Compliance:
      mandatory - This method must be implemented.
    • clearEventTerms

      void clearEventTerms()
      Clears the event terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchTimePeriodId

      void matchTimePeriodId(Id timePeriodId, boolean match)
      Sets the time period Id for this query.
      Parameters:
      timePeriodId - a time period Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - timePeriodId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearTimePeriodIdTerms

      void clearTimePeriodIdTerms()
      Clears the time period Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsTimePeriodQuery

      boolean supportsTimePeriodQuery()
      Tests if a TimePeriodQuery is available.
      Returns:
      true if a time period query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getTimePeriodQuery

      TimePeriodQuery getTimePeriodQuery()
      Gets the query for a time period. Multiple retrievals produce a nested OR term.
      Returns:
      the tiem period query
      Throws:
      UnimplementedException - supportsTimePeriodQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsTimePeriodQuery()} is {@code true} .
    • matchAnyTimePeriod

      void matchAnyTimePeriod(boolean match)
      Matches a calendar that has any time period assigned.
      Parameters:
      match - true to match calendars with any time period, false to match calendars with no time periods
      Compliance:
      mandatory - This method must be implemented.
    • clearTimePeriodTerms

      void clearTimePeriodTerms()
      Clears the time period terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchCommitmentId

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

      void clearCommitmentIdTerms()
      Clears the commitment Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsCommitmentQuery

      boolean supportsCommitmentQuery()
      Tests if a CommitmentQuery is available.
      Returns:
      true if a commitment query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getCommitmentQuery

      CommitmentQuery getCommitmentQuery()
      Gets the query for a commitment. Multiple retrievals produce a nested OR term.
      Returns:
      the commitment query
      Throws:
      UnimplementedException - supportsCommitmentQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsCommitmentQuery()} is {@code true} .
    • matchAnyCommitment

      void matchAnyCommitment(boolean match)
      Matches a calendar that has any event commitment.
      Parameters:
      match - true to match calendars with any commitment, false to match calendars with no commitments
      Compliance:
      mandatory - This method must be implemented.
    • clearCommitmentTerms

      void clearCommitmentTerms()
      Clears the commitment terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchAncestorCalendarId

      void matchAncestorCalendarId(Id calendarId, boolean match)
      Sets the calendar Id for this query to match calendars that have the specified calendar as an ancestor.
      Parameters:
      calendarId - a calendar Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - calendarId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearAncestorCalendarIdTerms

      void clearAncestorCalendarIdTerms()
      Clears the ancestor calendar Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsAncestorCalendarQuery

      boolean supportsAncestorCalendarQuery()
      Tests if a CalendarQuery is available.
      Returns:
      true if a calendar query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getAncestorCalendarQuery

      CalendarQuery getAncestorCalendarQuery()
      Gets the query for a calendar. Multiple retrievals produce a nested OR term.
      Returns:
      the calendar query
      Throws:
      UnimplementedException - supportsAncestorCalendarQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsAncestorCalndarQuery()} is {@code true} .
    • matchAnyAncestorCalendar

      void matchAnyAncestorCalendar(boolean match)
      Matches a calendar that has any ancestor.
      Parameters:
      match - true to match calendars with any ancestor, false to match root calendars
      Compliance:
      mandatory - This method must be implemented.
    • clearAncestorCalendarTerms

      void clearAncestorCalendarTerms()
      Clears the ancestor calendar terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchDescendantCalendarId

      void matchDescendantCalendarId(Id calendarId, boolean match)
      Sets the calendar Id for this query to match calendars that have the specified calendar as a descendant.
      Parameters:
      calendarId - a calendar Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - calendarId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearDescendantCalendarIdTerms

      void clearDescendantCalendarIdTerms()
      Clears the descendant calendar Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsDescendantCalendarQuery

      boolean supportsDescendantCalendarQuery()
      Tests if a CalendarQuery .
      Returns:
      true if a calendar query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getDescendantCalendarQuery

      CalendarQuery getDescendantCalendarQuery()
      Gets the query for a calendar. Multiple retrievals produce a nested OR term.
      Returns:
      the calendar query
      Throws:
      UnimplementedException - supportsDescendantCalendarQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsDescendantCalndarQuery()} is {@code true} .
    • matchAnyDescendantCalendar

      void matchAnyDescendantCalendar(boolean match)
      Matches a calendar that has any descendant.
      Parameters:
      match - true to match calendars with any descendant, false to match leaf calendars
      Compliance:
      mandatory - This method must be implemented.
    • clearDescendantCalendarTerms

      void clearDescendantCalendarTerms()
      Clears the descendant calendar terms.
      Compliance:
      mandatory - This method must be implemented.
    • getCalendarQueryRecord

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