Interface GradeEntryLookupSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface GradeEntryLookupSession extends OsidSession

This session provides methods for retrieving GradeEntrie s.

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 gradebook view: All grade entry methods in this session operate, retrieve and pertain to grade entries defined explicitly in the current gradebook. Using an isolated view is useful for managing grade entries with the GradeEntryAdminSession .
  • federated gradebook view: All grade entry methods in this session operate, retrieve and pertain to all grade entries defined in this gradebook and any other gradebooks implicitly available in this gradebook through gradebook inheritence.
  • effective grade entry view: All grade entry lookup methods return entries where the current date falls in between the effective dates inclusive.
  • any effective grade entry view: Grade entries of any effective date are returned from methods.

Grade entries may have an additional records indicated by their respective record types. The record may not be accessed through a cast of the GradeEntry .

  • Method Details

    • getGradebookId

      Id getGradebookId()
      Gets the Gradebook Id associated with this session.
      Returns:
      the Gradebook Id associated with this session
      Compliance:
      mandatory - This method must be implemented.
    • getGradebook

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

      boolean canLookupGradeEntries()
      Tests if this user can perform GradeEntry lookups. 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.
    • useComparativeGradeEntryView

      void useComparativeGradeEntryView()
      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.
    • usePlenaryGradeEntryView

      void usePlenaryGradeEntryView()
      A complete view of the GradeEntry 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.
    • useFederatedGradebookView

      void useFederatedGradebookView()
      Federates the view for methods in this session. A federated view will include grade entries in gradebooks which are children of this gradebook in the gradebook hierarchy.
      Compliance:
      mandatory - This method is must be implemented.
    • useIsolatedGradebookView

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

      void useEffectiveGradeEntryView()
      Only grade entries whose effective dates are current are returned by methods in this session.
      Compliance:
      mandatory - This method is must be implemented.
    • useAnyEffectiveGradeEntryView

      void useAnyEffectiveGradeEntryView()
      All grade entries of any effective dates are returned by methods in this session.
      Compliance:
      mandatory - This method is must be implemented.
    • getGradeEntry

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

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

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

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

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

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

      GradeEntryList getGradeEntriesForGradebookColumn(Id gradebookColumnId) throws OperationFailedException, PermissionDeniedException
      Gets a GradeEntryList for the gradebook column. In plenary mode, the returned list contains all known grade entries or an error results. Otherwise, the returned list may contain only those grade entries that are accessible through this session. In effective mode, grade entries are returned that are currently effective. In any effective mode, effective grade entries and those currently expired are returned.
      Parameters:
      gradebookColumnId - a gradebook column Id
      Returns:
      the returned GradeEntry list
      Throws:
      NullArgumentException - gradebookColumnId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getGradeEntriesForGradebookColumnOnDate

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

      GradeEntryList getGradeEntriesForResource(Id resourceId) throws OperationFailedException, PermissionDeniedException
      Gets a GradeEntryList for the given key key resource. In plenary mode, the returned list contains all known grade entries or an error results. Otherwise, the returned list may contain only those grade entries that are accessible through this session. In effective mode, grade entries are returned that are currently effective. In any effective mode, effective grade entries and those currently expired are returned.
      Parameters:
      resourceId - a key resource Id
      Returns:
      the returned GradeEntry list
      Throws:
      NullArgumentException - resourceId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getGradeEntriesForResourceOnDate

      GradeEntryList getGradeEntriesForResourceOnDate(Id resourceId, DateTime from, DateTime to) throws OperationFailedException, PermissionDeniedException
      Gets a GradeEntryList for the given key 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 grade entries or an error results. Otherwise, the returned list may contain only those grade entries that are accessible through this session. In effective mode, grade entries are returned that are currently effective. In any effective mode, effective grade entries and those currently expired are returned.
      Parameters:
      resourceId - a resource Id
      from - start of date range
      to - end of date range
      Returns:
      the returned GradeEntry list
      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.
    • getGradeEntriesForGradebookColumnAndResource

      GradeEntryList getGradeEntriesForGradebookColumnAndResource(Id gradebookColumnId, Id resourceId) throws OperationFailedException, PermissionDeniedException
      Gets a GradeEntryList for the gradebook column and key resource. In plenary mode, the returned list contains all known grade entries or an error results. Otherwise, the returned list may contain only those grade entries that are accessible through this session. In effective mode, grade entries are returned that are currently effective. In any effective mode, effective grade entries and those currently expired are returned.
      Parameters:
      gradebookColumnId - a gradebook column Id
      resourceId - a key resource Id
      Returns:
      the returned GradeEntry list
      Throws:
      NullArgumentException - gradebookColumnId or resourceId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getGradeEntriesForGradebookColumnAndResourceOnDate

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

      GradeEntryList getGradeEntriesByGrader(Id resourceId) throws OperationFailedException, PermissionDeniedException
      Gets a GradeEntryList for the given grader. In plenary mode, the returned list contains all known grade entries or an error results. Otherwise, the returned list may contain only those grade entries that are accessible through this session. In effective mode, grade entries are returned that are currently effective. In any effective mode, effective grade entries and those currently expired are returned.
      Parameters:
      resourceId - a resource Id
      Returns:
      the returned GradeEntry list
      Throws:
      NullArgumentException - resourceId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getGradeEntries

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