Interface QueueProcessorDistributorAssignmentSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface QueueProcessorDistributorAssignmentSession extends OsidSession

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

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

  • Method Details

    • canAssignQueueProcessors

      boolean canAssignQueueProcessors()
      Tests if this user can alter queue processor/distributor 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.
    • canAssignQueueProcessorToDistributor

      boolean canAssignQueueProcessorToDistributor(Id distributorId)
      Tests if this user can alter queue processor/distributor 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:
      distributorId - the Id of the Distributor
      Returns:
      false if mapping is not authorized, true otherwise
      Throws:
      NullArgumentException - distributorId is null
      Compliance:
      mandatory - This method must be implemented.
    • getAssignableDistributorIds

      IdList getAssignableDistributorIds(Id distributorId) throws OperationFailedException
      Gets a list of distributors including and under the given distributor node in which any queue processor can be assigned.
      Parameters:
      distributorId - the Id of the Distributor
      Returns:
      list of assignable distributor Ids
      Throws:
      NullArgumentException - distributorId is null
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • getAssignableDistributorIdsForQueueProcessor

      IdList getAssignableDistributorIdsForQueueProcessor(Id distributorId, Id queueProcessorId) throws OperationFailedException
      Gets a list of distributors including and under the given distributor node in which a specific queue processor can be assigned.
      Parameters:
      distributorId - the Id of the Distributor
      queueProcessorId - the Id of the QueueProcessor
      Returns:
      list of assignable distributor Ids
      Throws:
      NullArgumentException - distributorId or queueProcessorId is null
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • assignQueueProcessorToDistributor

      void assignQueueProcessorToDistributor(Id queueProcessorId, Id distributorId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Adds an existing QueueProcessor to a Distributor .
      Parameters:
      queueProcessorId - the Id of the QueueProcessor
      distributorId - the Id of the Distributor
      Throws:
      AlreadyExistsException - queueProcessorId is already assigned to distributorId
      NotFoundException - queueProcessorId or distributorId not found
      NullArgumentException - queueProcessorId or distributorId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • unassignQueueProcessorFromDistributor

      void unassignQueueProcessorFromDistributor(Id queueProcessorId, Id distributorId) throws NotFoundException, OperationFailedException, PermissionDeniedException
      Removes a QueueProcessor from a Distributor .
      Parameters:
      queueProcessorId - the Id of the QueueProcessor
      distributorId - the Id of the Distributor
      Throws:
      NotFoundException - queueProcessorId or distributorId not found or queueProcessorId not assigned to distributorId
      NullArgumentException - queueProcessorId or distributorId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • reassignQueueProcessorToDistributor

      void reassignQueueProcessorToDistributor(Id queueProcessorId, Id fromDistributorId, Id toDistributorId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Moves a QueueProcessor from one Distributor to another. Mappings to other Distributors are unaffected.
      Parameters:
      queueProcessorId - the Id of the QueueProcessor
      fromDistributorId - the Id of the current Distributor
      toDistributorId - the Id of the destination Distributor
      Throws:
      AlreadyExistsException - queueProcessorId already assigned to toDistributorId
      NotFoundException - queueProcessorId, fromDistributorId , or toDistributorId not found or queueProcessorId not mapped to fromDistributorId
      NullArgumentException - queueProcessorId, fromDistributorId , or toDistributorId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.