Interface CommissionEnablerFoundryAssignmentSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface CommissionEnablerFoundryAssignmentSession extends OsidSession

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

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

  • Method Details

    • canAssignCommissionEnablers

      boolean canAssignCommissionEnablers()
      Tests if this user can alter commission enabler/foundry 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 lookup operations to unauthorized users.
      Returns:
      false if mapping is not authorized, true otherwise
      Compliance:
      mandatory - This method must be implemented.
    • canAssignCommissionEnablersToFoundry

      boolean canAssignCommissionEnablersToFoundry(Id foundryId)
      Tests if this user can alter commission enabler/foundry 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 lookup operations to unauthorized users.
      Parameters:
      foundryId - the Id of the Foundry
      Returns:
      false if mapping is not authorized, true otherwise
      Throws:
      NullArgumentException - foundryId is null
      Compliance:
      mandatory - This method must be implemented.
    • getAssignableFoundryIds

      IdList getAssignableFoundryIds(Id foundryId) throws OperationFailedException
      Gets a list of foundries including and under the given foundry node in which any commission enabler can be assigned.
      Parameters:
      foundryId - the Id of the Foundry
      Returns:
      list of assignable foundry Ids
      Throws:
      NullArgumentException - foundryId is null
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • getAssignableFoundryIdsForCommissionEnabler

      IdList getAssignableFoundryIdsForCommissionEnabler(Id foundryId, Id commissionEnablerId) throws OperationFailedException
      Gets a list of foundries including and under the given foundry node in which a specific commission enabler can be assigned.
      Parameters:
      foundryId - the Id of the Foundry
      commissionEnablerId - the Id of the CommissionEnabler
      Returns:
      list of assignable foundry Ids
      Throws:
      NullArgumentException - foundryId or commissionEnablerId is null
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • assignCommissionEnablerToFoundry

      void assignCommissionEnablerToFoundry(Id commissionEnablerId, Id foundryId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Adds an existing CommissionEnabler to a Foundry .
      Parameters:
      commissionEnablerId - the Id of the CommissionEnabler
      foundryId - the Id of the Foundry
      Throws:
      AlreadyExistsException - ccommissionEnablerId is already assigned to foundryId
      NotFoundException - ccommissionEnablerId or foundryId not found
      NullArgumentException - commissionEnablerId or foundryId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • unassignCommissionEnablerFromFoundry

      void unassignCommissionEnablerFromFoundry(Id commissionEnablerId, Id foundryId) throws NotFoundException, OperationFailedException, PermissionDeniedException
      Removes a CommissionEnabler from a Foundry .
      Parameters:
      commissionEnablerId - the Id of the CommissionEnabler
      foundryId - the Id of the Foundry
      Throws:
      NotFoundException - commissionEnablerId or foundryId not found or commissionEnablerId not assigned to foundryId
      NullArgumentException - commissionEnablerId or foundryId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • reassignCommissionEnablerToFoundry

      void reassignCommissionEnablerToFoundry(Id commissionEnablerId, Id fromFoundryId, Id toFoundryId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Moves a CommissionEnabler from one Foundry to another. Mappings to other Foundries are unaffected.
      Parameters:
      commissionEnablerId - the Id of the CommissionEnabler
      fromFoundryId - the Id of the current Foundry
      toFoundryId - the Id of the destination Foundry
      Throws:
      AlreadyExistsException - commissionEnablerId already assigned to toFoundryId
      NotFoundException - commissionEnablerId, fromFoundryId , or toFoundryId not found or commissionEnablerId not mapped to fromFoundryId
      NullArgumentException - commissionEnablerId, fromFoundryId , or toFoundryId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.