Interface QueueEnablerDistributorAssignmentSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface QueueEnablerDistributorAssignmentSession extends OsidSession

This session provides methods to re-assign QueueEnabler to Distributor mappings. A QueueEnabler may appear in multiple Distributor catalogs and removing the last reference to a QueueEnabler 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 QueueEnabler to another Distributor is not a copy operation (eg: does not change its Id ).

  • Method Details

    • canAssignQueueEnablers

      boolean canAssignQueueEnablers()
      Tests if this user can alter queue enabler/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.
    • canAssignQueueEnablerToDistributor

      boolean canAssignQueueEnablerToDistributor(Id distributorId)
      Tests if this user can alter queue enabler/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 enabler 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.
    • getAssignableDistributorIdsForQueueEnabler

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

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

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

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