Interface InputSystemAssignmentSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface InputSystemAssignmentSession extends OsidSession

This session provides methods to re-assign Inputs to System mappings. A Input may appear in multiple Systems and removing the last reference to a Input is the equivalent of deleting it. Each System may have its own authorizations governing who is allowed to operate on it.

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

  • Method Details

    • canAssignInputs

      boolean canAssignInputs()
      Tests if this user can alter input/system 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 input assignment is not authorized, true otherwise
      Compliance:
      mandatory - This method must be implemented.
    • canAssignInputsToSystem

      boolean canAssignInputsToSystem(Id systemId)
      Tests if this user can alter input/system 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:
      systemId - the Id of the System
      Returns:
      false if input assignment is not authorized, true otherwise
      Throws:
      NullArgumentException - systemId is null
      Compliance:
      mandatory - This method must be implemented.
    • getAssignableSystemIds

      IdList getAssignableSystemIds(Id systemId) throws OperationFailedException
      Gets a list of systems including and under the given system node in which any input can be assigned.
      Parameters:
      systemId - the Id of the System
      Returns:
      list of assignable system Ids
      Throws:
      NullArgumentException - systemId is null
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • getAssignableSystemIdsForInput

      IdList getAssignableSystemIdsForInput(Id systemId, Id inputId) throws OperationFailedException
      Gets a list of systems including and under the given system node in which a specific input can be assigned.
      Parameters:
      systemId - the Id of the System
      inputId - the Id of the Input
      Returns:
      list of assignable system Ids
      Throws:
      NullArgumentException - systemId or inputId is null
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • assignInputToSystem

      void assignInputToSystem(Id inputId, Id systemId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Adds an existing Input to a System .
      Parameters:
      inputId - the Id of the Input
      systemId - the Id of the System
      Throws:
      AlreadyExistsException - inputId is already assigned to systemId
      NotFoundException - inputId or systemId not found
      NullArgumentException - inputId or systemId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • unassignInputFromSystem

      void unassignInputFromSystem(Id inputId, Id systemId) throws NotFoundException, OperationFailedException, PermissionDeniedException
      Removes a Input from a System .
      Parameters:
      inputId - the Id of the Input
      systemId - the Id of the System
      Throws:
      NotFoundException - inputId or systemId not found or inputId not assigned to systemId
      NullArgumentException - inputId or systemId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • reassignInputToSystem

      void reassignInputToSystem(Id inputId, Id fromSystemId, Id toSystemId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Moves an Input from one System to another. Mappings to other Systems are unaffected.
      Parameters:
      inputId - the Id of the Input
      fromSystemId - the Id of the current System
      toSystemId - the Id of the destination System
      Throws:
      AlreadyExistsException - inputId already assigned to toSystemId
      NotFoundException - inputId, fromSystemId , or toSystemId not found or inputId not mapped to fromSystemId
      NullArgumentException - inputId, fromSystemId , or toSystemId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.