Interface CommitmentLookupSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface CommitmentLookupSession extends OsidSession

This session provides methods for examining event commitments.

This session defines views that offer differing behaviors when retrieving multiple objects.

  • comparative view: elements may be silently omitted or re-ordered
  • plenary view: provides a complete set or is an error condition
  • isolated calendar view: All event methods in this session operate, retrieve and pertain to commitments defined explicitly in the current calendar. Using an isolated view is useful for managing events with the CommitmentAdminSession .
  • federated calendar view: All commitment methods in this session operate, retrieve and pertain to all commitments defined in this calendar and any other calendars implicitly available in this calendar through calendar inheritence.
  • effective commitment view: Commitment methods return only effective commitments
  • any effective commitment view: Commitment methods return all commitments
  • Method Details

    • getCalendarId

      Id getCalendarId()
      Gets the Calendar Id associated with this session.
      Returns:
      the Calendar Id associated with this session
      Compliance:
      mandatory - This method must be implemented.
    • getCalendar

      Gets the Calendar associated with this session.
      Returns:
      the Calendar associated with this session
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • canLookupCommitments

      boolean canLookupCommitments()
      Tests if this user can lookup event commitments. A return of true does not guarantee successful authorization. A return of false indicates that it is known all methods in this session will result in a PERMISSION_DENIED . This is intended as a hint to an application that may opt not to offer lookup operations to unauthorized users.
      Returns:
      false if lookup methods are not authorized, true otherwise
      Compliance:
      mandatory - This method must be implemented.
    • useComparativeCommitmentView

      void useComparativeCommitmentView()
      The returns from the lookup methods may omit or translate elements based on this session, such as authorization, and not result in an error. This view is used when greater interoperability is desired at the expense of precision.
      Compliance:
      mandatory - This method is must be implemented.
    • usePlenaryCommitmentView

      void usePlenaryCommitmentView()
      A complete view of the Commitment returns is desired. Methods will return what is requested or result in an error. This view is used when greater precision is desired at the expense of interoperability.
      Compliance:
      mandatory - This method is must be implemented.
    • useFederatedCalendarView

      void useFederatedCalendarView()
      Federates the view for methods in this session. A federated view will include commitments in calendars which are children of this calendar in the calendar hierarchy.
      Compliance:
      mandatory - This method is must be implemented.
    • useIsolatedCalendarView

      void useIsolatedCalendarView()
      Isolates the view for methods in this session. An isolated view restricts lookups to this calendar only.
      Compliance:
      mandatory - This method is must be implemented.
    • useEffectiveCommitmentView

      void useEffectiveCommitmentView()
      The commitments in this lookup session return only commitments currently in effect.
      Compliance:
      mandatory - This method is must be implemented.
    • useAnyEffectiveCommitmentView

      void useAnyEffectiveCommitmentView()
      The commitments in this lookup session return both effective and ineffective commitments.
      Compliance:
      mandatory - This method is must be implemented.
    • getCommitment

      Gets the Commitment specified by its Id . In plenary mode, the exact Id is found or a NOT_FOUND results. Otherwise, the returned Commitment may have a different Id than requested, such as the case where a duplicate Id was assigned to a Commitment and retained for compatibility. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      commitmentId - Id of the Commitment
      Returns:
      the commitment
      Throws:
      NotFoundException - commitmentId not found
      NullArgumentException - commitmentId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method is must be implemented.
    • getCommitmentsByIds

      Gets a CommitmentList corresponding to the given IdList . In plenary mode, the returned list contains all of the commitments specified in the Id list, in the order of the list, including duplicates, or an error results if an Id in the supplied list is not found or inaccessible. Otherwise, inaccessible Commitments may be omitted from the list and may present the elements in any order including returning a unique set. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      commitmentIds - the list of Ids to retrieve
      Returns:
      the returned Commitment list
      Throws:
      NotFoundException - an Id was not found
      NullArgumentException - commitmentIds is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getCommitmentsByGenusType

      CommitmentList getCommitmentsByGenusType(Type commitmentGenusType) throws OperationFailedException, PermissionDeniedException
      Gets the commitments for the given event genus type. In plenary mode, the returned list contains all known commitments or an error results. Otherwise, the returned list may contain only those commitments that are accessible through this session. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      commitmentGenusType - commitment genus type
      Returns:
      list of commitments
      Throws:
      NullArgumentException - commitmentGenusType is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method is must be implemented.
    • getCommitmentsByParentGenusType

      CommitmentList getCommitmentsByParentGenusType(Type commitmentGenusType) throws OperationFailedException, PermissionDeniedException
      Gets the commitments for the given event genus type and include any commitments with a genus type derived from the specified genus type. In plenary mode, the returned list contains all known commitments or an error results. Otherwise, the returned list may contain only those commitments that are accessible through this session. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      commitmentGenusType - commitment genus type
      Returns:
      list of commitments
      Throws:
      NullArgumentException - commitmentGenusType is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method is must be implemented.
    • getCommitmentsByRecordType

      CommitmentList getCommitmentsByRecordType(Type commitmentRecordType) throws OperationFailedException, PermissionDeniedException
      Gets a CommitmentList containing the given event commitment record Type . In plenary mode, the returned list contains all known commitments or an error results. Otherwise, the returned list may contain only those commitments that are accessible through this session. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      commitmentRecordType - a commitment record type
      Returns:
      list of commitments
      Throws:
      NullArgumentException - eventRecordType is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getCommitmentsOnDate

      Gets a CommitmentList effective during the entire given date range inclusive but not confined to the date range. In plenary mode, the returned list contains all known commitments or an error results. Otherwise, the returned list may contain only those commitments that are accessible through this session. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      from - starting date
      to - ending date
      Returns:
      list of commitments
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - from or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getCommitmentsByGenusTypeOnDate

      CommitmentList getCommitmentsByGenusTypeOnDate(Type commitmentGenusType, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
      Gets a CommitmentList of the given genus type and effective during the entire given date range inclusive but not confined to the date range. In plenary mode, the returned list contains all known commitments or an error results. Otherwise, the returned list may contain only those commitments that are accessible through this session. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      commitmentGenusType - a commitment genus type
      from - starting date
      to - ending date
      Returns:
      list of commitments
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - commitmentGenusType, from , or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getCommitmentsForEvent

      CommitmentList getCommitmentsForEvent(Id eventId) throws OperationFailedException, PermissionDeniedException
      Gets the commitments for the given event. If the event is a recurring event, the commitments are returned for the recurring event only. In plenary mode, the returned list contains all of the commitments mapped to the event Id or an error results if an Id in the supplied list is not found or inaccessible. Otherwise, inaccessible Commitments may be omitted from the list and may present the elements in any order including returning a unique set. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      eventId - Id of the Event
      Returns:
      list of commitments
      Throws:
      NullArgumentException - eventId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method is must be implemented.
    • getCommitmentsForEventOnDate

      CommitmentList getCommitmentsForEventOnDate(Id eventId, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
      Gets a CommitmentList for the given event and effective during the entire given date range inclusive but not confined to the date range. In plenary mode, the returned list contains all known commitments or an error results. Otherwise, the returned list may contain only those commitments that are accessible through this session. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      eventId - Id of the Event
      from - starting date
      to - ending date
      Returns:
      list of commitments
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - eventId, from or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getCommitmentsByGenusTypeForEvent

      CommitmentList getCommitmentsByGenusTypeForEvent(Id eventId, Type commitmentGenusType) throws OperationFailedException, PermissionDeniedException
      Gets the commitments for the given event and commitment genus type including any genus types derived from the given genus type. If the event is a recurring event, the commitments are returned for the recurring event only. In plenary mode, the returned list contains all of the commitments mapped to the event Id or an error results if an Id in the supplied list is not found or inaccessible. Otherwise, inaccessible commitments may be ommitted. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      eventId - Id of the Event
      commitmentGenusType - commitment genus type
      Returns:
      list of commitments
      Throws:
      NullArgumentException - eventId or commitmentGenusType is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method is must be implemented.
    • getCommitmentsByGenusTypeForEventOnDate

      CommitmentList getCommitmentsByGenusTypeForEventOnDate(Id eventId, Type commitmentGenusType, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
      Gets a CommitmentList for the given event and commitment genus type effective during the entire given date range inclusive but not confined to the date range. In plenary mode, the returned list contains all known commitments or an error results. Otherwise, the returned list may contain only those commitments that are accessible through this session. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      eventId - Id of the Event
      commitmentGenusType - commitment genus type
      from - starting date
      to - ending date
      Returns:
      list of commitments
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - eventId, commitmentGenusType, from or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getCommitmentsForResource

      CommitmentList getCommitmentsForResource(Id resourceId) throws OperationFailedException, PermissionDeniedException
      Gets the commitments for the given resource. In plenary mode, the returned list contains all of the commitments mapped to the resource Id or an error results if an Id in the supplied list is not found or inaccessible. Otherwise, inaccessible Commitments may be omitted from the list and may present the elements in any order including returning a unique set. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      resourceId - Id of a Resource
      Returns:
      list of commitments
      Throws:
      NullArgumentException - resourceId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method is must be implemented.
    • getCommitmentsForResourceOnDate

      CommitmentList getCommitmentsForResourceOnDate(Id resourceId, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
      Gets a CommitmentList for the given resource and effective during the entire given date range inclusive but not confined to the date range. In plenary mode, the returned list contains all known commitments or an error results. Otherwise, the returned list may contain only those commitments that are accessible through this session. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      resourceId - Id of the Event
      from - starting date
      to - ending date
      Returns:
      list of commitments
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - resourceId, from or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getCommitmentsByGenusTypeForResource

      CommitmentList getCommitmentsByGenusTypeForResource(Id resourceId, Type commitmentGenusType) throws OperationFailedException, PermissionDeniedException
      Gets the commitments for the given resource and commitment genus type including any genus types derived from the given genus type. In plenary mode, the returned list contains all of the commitments mapped to the resource Id or an error results if an Id in the supplied list is not found or inaccessible. Otherwise, inaccessible Commitments may be omitted from the list and may present the elements in any order including returning a unique set. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      resourceId - Id of a Resource
      commitmentGenusType - commitment genus type
      Returns:
      list of commitments
      Throws:
      NullArgumentException - resourceId or commitmentGenusType is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method is must be implemented.
    • getCommitmentsByGenusTypeForResourceOnDate

      CommitmentList getCommitmentsByGenusTypeForResourceOnDate(Id resourceId, Type commitmentGenusType, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
      Gets a CommitmentList for the given resource, commitment genus type, and effective during the entire given date range inclusive but not confined to the date range. In plenary mode, the returned list contains all known commitments or an error results. Otherwise, the returned list may contain only those commitments that are accessible through this session. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      resourceId - Id of the Event
      commitmentGenusType - commitment genus type
      from - starting date
      to - ending date
      Returns:
      list of commitments
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - resourceId, commitmentGenusType, from or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getCommitmentsForEventAndResource

      CommitmentList getCommitmentsForEventAndResource(Id eventId, Id resourceId) throws OperationFailedException, PermissionDeniedException
      Gets the commitments for the given event and resource. If the event is a recurring event, the commitments are returned for the recurring event only. In plenary mode, the returned list contains all of the commitments mapped to the event Id or an error results if an Id in the supplied list is not found or inaccessible. Otherwise, inaccessible Commitments may be omitted from the list and may present the elements in any order including returning a unique set. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      eventId - Id of the Event
      resourceId - Id of a Resource
      Returns:
      list of commitments
      Throws:
      NullArgumentException - eventId or resourceId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method is must be implemented.
    • getCommitmentsForEventAndResourceOnDate

      CommitmentList getCommitmentsForEventAndResourceOnDate(Id eventId, Id resourceId, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
      Gets a CommitmentList for the given event and resource and effective during the entire given date range inclusive but not confined to the date range. In plenary mode, the returned list contains all known commitments or an error results. Otherwise, the returned list may contain only those commitments that are accessible through this session. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      eventId - Id of the Event
      resourceId - Id of a Resource
      from - starting date
      to - ending date
      Returns:
      list of commitments
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - eventId, resourceId, from or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getCommitmentsByGenusTypeForEventAndResource

      CommitmentList getCommitmentsByGenusTypeForEventAndResource(Id eventId, Id resourceId, Type commitmentGenusType) throws OperationFailedException, PermissionDeniedException
      Gets the commitments of the given genus type for the given event, resource, and commitment genus type including any genus types derived from the given genus type. If the event is a recurring event, the commitments are returned for the recurring event only. In plenary mode, the returned list contains all of the commitments mapped to the event Id or an error results if an Id in the supplied list is not found or inaccessible. Otherwise, inaccessible Commitments may be omitted from the list and may present the elements in any order including returning a unique set. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      eventId - Id of the Event
      resourceId - Id of a Resource
      commitmentGenusType - commitment genus type
      Returns:
      list of commitments
      Throws:
      NullArgumentException - eventId, resourceId or commitmentGenusType is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method is must be implemented.
    • getCommitmentsByGenusTypeForEventAndResourceOnDate

      CommitmentList getCommitmentsByGenusTypeForEventAndResourceOnDate(Id eventId, Id resourceId, Type commitmentGenusType, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
      Gets a CommitmentList of the given genus type for the given event, resource, commitment genus type and effective during the entire given date range inclusive but not confined to the date range. In plenary mode, the returned list contains all known commitments or an error results. Otherwise, the returned list may contain only those commitments that are accessible through this session. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Parameters:
      eventId - Id of the Event
      resourceId - Id of a Resource
      commitmentGenusType - commitment genus type
      from - starting date
      to - ending date
      Returns:
      list of commitments
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - eventId, resourceId, commitmentGenusType, from or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getCommitments

      Gets all commitments. In plenary mode, the returned list contains all known commitments or an error results. Otherwise, the returned list may contain only those commitments that are accessible through this session. In effective mode, commitments are returned that are currently effective. In any effective mode, effective commitments and those currently expired are returned.
      Returns:
      list of commitments
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method is must be implemented.