Interface RegistrationTargetCourseCatalogAssignmentSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface RegistrationTargetCourseCatalogAssignmentSession extends OsidSession

This session provides methods to re-assign RegistrationTa rgets to CourseCatalog mappings. A RegistrationT arget may appear in multiple CourseCatalog catalogs and removing the last reference to a RegistrationT arget is the equivalent of deleting it. Each CourseCatalog may have its own authorizations governing who is allowed to operate on it.

Adding a reference of a RegistrationT arget to another CourseCatalog is not a copy operation (eg: does not change its Id) .

  • Method Details

    • canAssignRegistrationTargets

      boolean canAssignRegistrationTargets()
      Tests if this user can alter registration target/course catalog 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. T his 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.
    • canAssignRegistrationTargetToCourseCatalog

      boolean canAssignRegistrationTargetToCourseCatalog(Id courseCatalogId)
      Tests if this user can alter registration target/course catalog 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. T his is intended as a hint to an application that may opt not to offer assignment operations to unauthorized users.
      Parameters:
      courseCatalogId - the Id of the CourseCatalog
      Returns:
      false if mapping is not authorized, true otherwise
      Throws:
      NullArgumentException - courseCatalogId is null
      Compliance:
      mandatory - This method must be implemented.
    • getAssignableCourseCatalogIds

      IdList getAssignableCourseCatalogIds(Id courseCatalogId) throws OperationFailedException
      Gets a list of course catalogs including and under the given course catalog node in which any registration target can be assigned.
      Parameters:
      courseCatalogId - the Id of the CourseCatalog
      Returns:
      list of assignable course catalog Ids
      Throws:
      NullArgumentException - courseCatalogId is null
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • getAssignableCourseCatalogIdsForRegistrationTarget

      IdList getAssignableCourseCatalogIdsForRegistrationTarget(Id courseCatalogId, Id registrationTargetId) throws OperationFailedException
      Gets a list of course catalogs including and under the given course catalog node in which a specific registration target can be assigned.
      Parameters:
      courseCatalogId - the Id of the CourseCatalog
      registrationTargetId - the Id of the RegistrationTarget
      Returns:
      list of assignable course catalog Ids
      Throws:
      NullArgumentException - courseCatalogId or registrationTargetId is null
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • assignRegistrationTargetToCourseCatalog

      void assignRegistrationTargetToCourseCatalog(Id registrationTargetId, Id courseCatalogId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Adds an existing RegistrationTarget to a CourseCatalog .
      Parameters:
      registrationTargetId - the Id of the RegistrationTarget
      courseCatalogId - the Id of the CourseCatalog
      Throws:
      AlreadyExistsException - registrationTargetId is already assigned to courseCatalogId
      NotFoundException - registrationTargetId or courseCatalogId not found
      NullArgumentException - registrationTargetId or courseCatalogId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • unassignRegistrationTargetFromCourseCatalog

      void unassignRegistrationTargetFromCourseCatalog(Id registrationTargetId, Id courseCatalogId) throws NotFoundException, OperationFailedException, PermissionDeniedException
      Removes a RegistrationTarget from a CourseCatalog .
      Parameters:
      registrationTargetId - the Id of the RegistrationTarget
      courseCatalogId - the Id of the CourseCatalog
      Throws:
      NotFoundException - registrationTargetId or courseCatalogId not found or registrationTargetId not assigned to courseCatalogId
      NullArgumentException - registrationTargetId or courseCatalogId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • reassignRegistrationTargetToCourseCatalog

      void reassignRegistrationTargetToCourseCatalog(Id registrationTargetId, Id fromCourseCatalogId, Id toCourseCatalogId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Moves a RegistrationTarget from one CourseCatalog to another. Mappings to other CourseCatalogs are unaffected.
      Parameters:
      registrationTargetId - the Id of the RegistrationTarget
      fromCourseCatalogId - the Id of the current CourseCatalog
      toCourseCatalogId - the Id of the destination CourseCatalog
      Throws:
      AlreadyExistsException - registrationTargetId already assigned to tocourseCatalogId
      NotFoundException - registrationTargetId, fromCourseCatalogId , or toCourseCatalogeId not found or registrationTargetId not mapped to fromCourseCatalogId
      NullArgumentException - registrationTargetId, fromCourseCatalogId , or toCourseCatalogId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.