Interface GradeSystemGradebookAssignmentSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface GradeSystemGradebookAssignmentSession extends OsidSession

This session provides methods to re-assign grade systems to Gradebooks . A GradeSystem may map to multiple Gradebooks and removing the last reference to a GradeSystem is the equivalent of deleting it. Each Gradebook may have its own authorizations governing who is allowed to operate on it.

Moving or adding a reference of a GradeSystem to another Gradebook is not a copy operation (eg: does not change its Id ).

  • Method Details

    • canAssignGradeSystem

      boolean canAssignGradeSystem()
      Tests if this user can alter grade system/gradebook mappings. A return of true does not guarantee successful authorization. A return of false indicates that it is known mapping 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 assignment operations to unauthorized users.
      Returns:
      false if mapping is not authorized, true otherwise
      Compliance:
      mandatory - This method must be implemented.
    • canAssignGradeSystemsToGradebook

      boolean canAssignGradeSystemsToGradebook(Id gradebookId)
      Tests if this user can alter grade system/gradebook mappings. A return of true does not guarantee successful authorization. A return of false indicates that it is known mapping 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 assignment operations to unauthorized users.
      Parameters:
      gradebookId - the Id of the Gradebook
      Returns:
      false if mapping is not authorized, true otherwise
      Throws:
      NullArgumentException - gradebookId is null
      Compliance:
      mandatory - This method must be implemented.
    • getAssignableGradebookIds

      IdList getAssignableGradebookIds(Id gradebookId) throws OperationFailedException
      Gets a list of gradebooks including and under the given gradebook node in which any grade system can be assigned.
      Parameters:
      gradebookId - the Id of the Gradebook
      Returns:
      list of assignable gradebook Ids
      Throws:
      NullArgumentException - gradebookId is null
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • getAssignableGradebookIdsForGradeSystem

      IdList getAssignableGradebookIdsForGradeSystem(Id gradebookId, Id gradeSystemId) throws OperationFailedException
      Gets a list of gradebooks including and under the given gradebook node in which a specific grade system can be assigned.
      Parameters:
      gradebookId - the Id of the Gradebook
      gradeSystemId - the Id of the GradeSystem
      Returns:
      list of assignable gradebook Ids
      Throws:
      NullArgumentException - gradebookId or gradeSystemId is null
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • assignGradeSystemToGradebook

      void assignGradeSystemToGradebook(Id gradeSystemId, Id gradebookId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Adds an existing GradeSystem to a Gradebook .
      Parameters:
      gradeSystemId - the Id of the GradeSystem
      gradebookId - the Id of the Gradebook
      Throws:
      AlreadyExistsException - gradeSystemId is already assigned to gradebookId
      NotFoundException - gradeSystemId or gradebookId not found
      NullArgumentException - gradeSystemId or gradebookId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • unassignGradeSystemFromGradebook

      void unassignGradeSystemFromGradebook(Id gradeSystemId, Id gradebookId) throws NotFoundException, OperationFailedException, PermissionDeniedException
      Removes a GradeSystem from a Gradebook .
      Parameters:
      gradeSystemId - the Id of the GradeSystem
      gradebookId - the Id of the Gradebook
      Throws:
      NotFoundException - gradeSystemId or gradebookId not found or gradeSystemId not assigned to gradebookId
      NullArgumentException - gradeSystemId or gradebookId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • reassignGradeSystemToGradebook

      void reassignGradeSystemToGradebook(Id gradeSystemId, Id fromGradebookId, Id toGradebookId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Moves a GradeSystem from one Gradebook to another. Mappings to other Gradebooks are unaffected.
      Parameters:
      gradeSystemId - the Id of the GradeSystem
      fromGradebookId - the Id of the current Gradebook
      toGradebookId - the Id of the destination Gradebook
      Throws:
      AlreadyExistsException - gradebookSystemId already assigned to toGradebookId
      NotFoundException - gradeSystemId, fromGradebookId , or toGradebookId not found or gradeSystemId not mapped to fromGradebookId
      NullArgumentException - gradeSystemId, fromGradebookId , or toGradebookId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.