Interface ConferralAcademyAssignmentSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface ConferralAcademyAssignmentSession extends OsidSession

This session provides methods to re-assign Conferrals to Academies . A Conferral may map to multiple Academies and removing the last reference to a Conferral is the equivalent of deleting it. Each Academy may have its own authorizations governing who is allowed to operate on it.

Adding a reference of a Conferral to another Academy is not a copy operation (eg: does not change its Id ).

  • Method Details

    • canAssignConferrals

      boolean canAssignConferrals()
      Tests if this user can alter conferral/academy 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.
    • canAssignConferralsToAcademy

      boolean canAssignConferralsToAcademy(Id academyId)
      Tests if this user can alter conferral/academy 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:
      academyId - the Id of the Academy
      Returns:
      false if mapping is not authorized, true otherwise
      Throws:
      NullArgumentException - academyId is null
      Compliance:
      mandatory - This method must be implemented.
    • getAssignableAcademyIds

      IdList getAssignableAcademyIds(Id academyId) throws OperationFailedException
      Gets a list of academies including and under the given academy node in which any conferral can be assigned.
      Parameters:
      academyId - the Id of the Academy
      Returns:
      list of assignable academy Ids
      Throws:
      NullArgumentException - academyId is null
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • getAssignableAcademyIdsForConferral

      IdList getAssignableAcademyIdsForConferral(Id academyId, Id conferralId) throws OperationFailedException
      Gets a list of academies including and under the given academy node in which a specific conferral can be assigned.
      Parameters:
      academyId - the Id of the Academy
      conferralId - the Id of the Conferral
      Returns:
      list of assignable academy Ids
      Throws:
      NullArgumentException - academyId or conferralId is null
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • assignConferralToAcademy

      void assignConferralToAcademy(Id conferralId, Id academyId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Adds an existing Conferral to an Academy .
      Parameters:
      conferralId - the Id of the Conferral
      academyId - the Id of the Academy
      Throws:
      AlreadyExistsException - conferralId is already assigned to academyId
      NotFoundException - conferralId or academyId not found
      NullArgumentException - conferralId or academyId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • unassignConferralFromAcademy

      void unassignConferralFromAcademy(Id conferralId, Id academyId) throws NotFoundException, OperationFailedException, PermissionDeniedException
      Removes a Conferral from an Academy .
      Parameters:
      conferralId - the Id of the Conferral
      academyId - the Id of the Academy
      Throws:
      NotFoundException - conferralId or academyId not found or conferralId not assigned to academyId
      NullArgumentException - conferralId or academyId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • reassignConferralToAcademy

      void reassignConferralToAcademy(Id conferralId, Id fromAcademyId, Id toAcademyId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Moves a Conferral from one Academy to another. Mappings to other Academies are unaffected.
      Parameters:
      conferralId - the Id of the Conferral
      fromAcademyId - the Id of the current Academy
      toAcademyId - the Id of the destination Academy
      Throws:
      AlreadyExistsException - conferralId already assigned to toAcademyId
      NotFoundException - conferralId, fromAcademyId , or toAcademyId not found or conferralId not mapped to fromAcademyId
      NullArgumentException - conferralId, fromAcademyId , or toAcademyId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.