Interface OfferingLookupSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface OfferingLookupSession extends OsidSession

This session defines methods for retrieving offerings.

This lookup session defines several views:

  • comparative view: elements may be silently omitted or re-ordered
  • plenary view: provides a complete result set or is an error condition
  • isolated catalogue view: All offering methods in this session operate, retrieve and pertain to offerings defined explicitly in the current catalogue. Using an isolated view is useful for managing offerings with the OfferingAdminSession .
  • federated catalogue view: All offering lookup methods in this session operate, retrieve and pertain to all offerings defined in this catalogue and any other catalogues implicitly available in this catalogue through catalogue inheritence.
  • effective offering view: All offering lookup methods return offerings where the current date falls in between the effective dates inclusive.
  • any status offering view: Offerings of any effective date are returned from methods.

The methods useFederatedCatalogueView() and useIsolatedCatalogueView() behave as a radio group and one should be selected before invoking any lookup methods.

  • Method Details

    • getCatalogueId

      Id getCatalogueId()
      Gets the Catalogue Id associated with this session.
      Returns:
      the Catalogue Id associated with this session
      Compliance:
      mandatory - This method must be implemented.
    • getCatalogue

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

      boolean canLookupOfferings()
      Tests if this user can examine this catalogue. 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 these operations.
      Returns:
      false if catalogue reading methods are not authorized, true otherwise
      Compliance:
      mandatory - This method must be implemented.
    • useComparativeOfferingView

      void useComparativeOfferingView()
      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.
    • usePlenaryOfferingView

      void usePlenaryOfferingView()
      A complete view of the Offering 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.
    • useFederatedCatalogueView

      void useFederatedCatalogueView()
      Federates the view for methods in this session. A federated view will include offerings in catalogues which are children of this catalogue in the catalogue hierarchy.
      Compliance:
      mandatory - This method is must be implemented.
    • useIsolatedCatalogueView

      void useIsolatedCatalogueView()
      Isolates the view for methods in this session. An isolated view restricts retrievals to this catalogue only.
      Compliance:
      mandatory - This method is must be implemented.
    • useEffectiveOfferingView

      void useEffectiveOfferingView()
      Only offerings whose effective dates are current are returned by methods in this session.
      Compliance:
      mandatory - This method is must be implemented.
    • useAnyEffectiveOfferingView

      void useAnyEffectiveOfferingView()
      All offerings of any effective dates are returned by methods in this session.
      Compliance:
      mandatory - This method is must be implemented.
    • getOffering

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

      Gets an OfferingList corresponding to the given IdList . In plenary mode, the returned list contains all of the offerings 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 offerings may be omitted from the list and may present the elements in any order including returning a unique set. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      offeringIds - the list of Ids to retrieve
      Returns:
      the returned Offering list
      Throws:
      NotFoundException - an Id was not found
      NullArgumentException - offeringIds is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingsByGenusType

      OfferingList getOfferingsByGenusType(Type offeringGenusType) throws OperationFailedException, PermissionDeniedException
      Gets an OfferingList corresponding to the given offering genus Type which does not include offerings of types derived from the specified Type . In plenary mode, the returned list contains all known offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      offeringGenusType - an offerings genus type
      Returns:
      the returned Offering list
      Throws:
      NullArgumentException - offeringGenusType is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingsByParentGenusType

      OfferingList getOfferingsByParentGenusType(Type offeringGenusType) throws OperationFailedException, PermissionDeniedException
      Gets an OfferingList corresponding to the given offering genus Type and include any additional offerings with genus types derived from the specified Type . In plenary mode, the returned list contains all known offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      offeringGenusType - an offering genus type
      Returns:
      the returned Offering list
      Throws:
      NullArgumentException - offeringGenusType is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingsByRecordType

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

      Gets an OfferingList effective during the entire given date range inclusive but not confined to the date range. In plenary mode, the returned list contains all known offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      from - start of date range
      to - end of date range
      Returns:
      the returned OfferingList
      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.
    • getOfferingsByGenusTypeOnDate

      OfferingList getOfferingsByGenusTypeOnDate(Type offeringGenusType, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
      Gets an OfferingList by 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 offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      offeringGenusType - an offering genus type
      from - start of date range
      to - end of date range
      Returns:
      the returned OfferingList
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - offeringGenusType, from , or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingsForCanonicalUnit

      OfferingList getOfferingsForCanonicalUnit(Id canonicalUnitId) throws OperationFailedException, PermissionDeniedException
      Gets an OfferingList for the given canonical unit. In plenary mode, the returned list contains all known offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      canonicalUnitId - a canonical unit Id
      Returns:
      the returned OfferingList
      Throws:
      NullArgumentException - canonicalUnitId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingsByGenusTypeForCanonicalUnit

      OfferingList getOfferingsByGenusTypeForCanonicalUnit(Id canonicalUnitId, Type offeringGenusType) throws OperationFailedException, PermissionDeniedException
      Gets an OfferingList by genus type for the given canonical unit. In plenary mode, the returned list contains all known offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      canonicalUnitId - a canonical unit Id
      offeringGenusType - an offering genus type
      Returns:
      the returned OfferingList
      Throws:
      NullArgumentException - canonicalUnitId or offeringGenusType is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingsForCanonicalUnitOnDate

      OfferingList getOfferingsForCanonicalUnitOnDate(Id canonicalUnitId, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
      Gets an OfferingList for the given canonical unit 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 offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      canonicalUnitId - a canonical unit Id
      from - start of date range
      to - end of date range
      Returns:
      the returned OfferingList
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - canonicalUnitId, from , or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingsByGenusTypeForCanonicalUnitOnDate

      OfferingList getOfferingsByGenusTypeForCanonicalUnitOnDate(Id canonicalUnitId, Type offeringGenusType, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
      Gets an OfferingList by genus type for the given canonical unit 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 offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      canonicalUnitId - a canonical unit Id
      offeringGenusType - an offering genus type
      from - start of date range
      to - end of date range
      Returns:
      the returned OfferingList
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - canonicalUnitId, offeringGenusType, from , or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingsForTimePeriod

      OfferingList getOfferingsForTimePeriod(Id timePeriodId) throws OperationFailedException, PermissionDeniedException
      Gets an OfferingList for the given time period. In plenary mode, the returned list contains all known offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      timePeriodId - a time period Id
      Returns:
      the returned OfferingList
      Throws:
      NullArgumentException - timePeriodId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingsByGenusTypeForTimePeriod

      OfferingList getOfferingsByGenusTypeForTimePeriod(Id timePeriodId, Type offeringGenusType) throws OperationFailedException, PermissionDeniedException
      Gets an OfferingList by genus type for the given time period. In plenary mode, the returned list contains all known offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      timePeriodId - a time period Id
      offeringGenusType - an offering genus type
      Returns:
      the returned OfferingList
      Throws:
      NullArgumentException - timePeriodId or offeringGenusType is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingsForTimePeriodOnDate

      OfferingList getOfferingsForTimePeriodOnDate(Id timePeriodId, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
      Gets an OfferingList for the given time period 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 offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      timePeriodId - a time period Id
      from - start of date range
      to - end of date range
      Returns:
      the returned OfferingList
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - timePeriodId, from , or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingsByGenusTypeForTimePeriodOnDate

      OfferingList getOfferingsByGenusTypeForTimePeriodOnDate(Id timePeriodId, Type offeringGenusType, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
      Gets an OfferingList by genus type for the given time period 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 offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      timePeriodId - a time period Id
      offeringGenusType - an offering genus type
      from - start of date range
      to - end of date range
      Returns:
      the returned OfferingList
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - timePeriodId, offeringGenusType, from , or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingsForCanonicalUnitAndTimePeriod

      OfferingList getOfferingsForCanonicalUnitAndTimePeriod(Id canonicalUnitId, Id timePeriodId) throws OperationFailedException, PermissionDeniedException
      Gets an OfferingList for the given canonical unit and time period. In plenary mode, the returned list contains all known offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      canonicalUnitId - a canonical unit Id
      timePeriodId - a time period Id
      Returns:
      the returned OfferingList
      Throws:
      NullArgumentException - canonicalUnitId or timePeriodId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingsByGenusTypeForCanonicalUnitAndTimePeriod

      OfferingList getOfferingsByGenusTypeForCanonicalUnitAndTimePeriod(Id canonicalUnitId, Id timePeriodId, Type offeringGenusType) throws OperationFailedException, PermissionDeniedException
      Gets an OfferingList by genus type for the given canonical unit and time period. In plenary mode, the returned list contains all known offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      canonicalUnitId - a canonical unit Id
      timePeriodId - a time period Id
      offeringGenusType - an offering genus type
      Returns:
      the returned OfferingList
      Throws:
      NullArgumentException - canonicalUnitId , timePeriodId , or offeringGenusType is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingsForCanonicalUnitAndTimePeriodOnDate

      OfferingList getOfferingsForCanonicalUnitAndTimePeriodOnDate(Id canonicalUnitId, Id timePeriodId, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
      Gets an OfferingList for the given canonical unit, time period, 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 offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      canonicalUnitId - a canonical unit Id
      timePeriodId - a time period Id
      from - start of date range
      to - end of date range
      Returns:
      the returned OfferingList
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - canonicalUnitId, timePeriodId, from , or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingsByGenusTypeForCanonicalUnitAndTimePeriodOnDate

      OfferingList getOfferingsByGenusTypeForCanonicalUnitAndTimePeriodOnDate(Id canonicalUnitId, Id timePeriodId, Type offeringGenusType, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
      Gets an OfferingList by genus type for the given canonical, time period, 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 offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      canonicalUnitId - a canonical unit Id
      timePeriodId - a time period Id
      offeringGenusType - an offering genus type
      from - start of date range
      to - end of date range
      Returns:
      the returned OfferingList
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - canonicalUnitId, timePeriodId, offeringGenusType, from , or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferingsByCodeAndTimePeriod

      OfferingList getOfferingsByCodeAndTimePeriod(String code, Id timePeriodId) throws OperationFailedException, PermissionDeniedException
      Gets an OfferingList by code and time period. In plenary mode, the returned list contains all known offerings or an error results. Otherwise, the returned list may contain only those offerings that are accessible through this session. In effective mode, offerings are returned that are currently effective. In any effective mode, effective offerings and those currently expired are returned.
      Parameters:
      code - a canonical unit Id
      timePeriodId - a time period Id
      Returns:
      the returned OfferingList
      Throws:
      NullArgumentException - code or timePeriodId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getOfferings

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