Interface AuctionAuctionHouseAssignmentSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface AuctionAuctionHouseAssignmentSession extends OsidSession

This session provides methods to re-assign Auctions to AuctionHouse mappings. An Auction may appear in multiple AuctionHouse objects and removing the last reference to an Auction is the equivalent of deleting it. Each AuctionHouse may have its own authorizations governing who is allowed to operate on it.

Adding a reference of an Auction to another AuctionHouse is not a copy operation (eg: does not change its Id ).

  • Method Details

    • canAssignAuctions

      boolean canAssignAuctions()
      Tests if this user can alter auction/auction house 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 mapping is not authorized, true otherwise
      Compliance:
      mandatory - This method must be implemented.
    • canAssignAuctionsToAuctionHouse

      boolean canAssignAuctionsToAuctionHouse(Id auctionHouseId)
      Tests if this user can alter auction/auction house 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:
      auctionHouseId - the Id of the AuctionHouse
      Returns:
      false if mapping is not authorized, true otherwise
      Throws:
      NullArgumentException - auctionHouseId is null
      Compliance:
      mandatory - This method must be implemented.
    • getAssignableAuctionHouseIds

      IdList getAssignableAuctionHouseIds(Id auctionHouseId) throws OperationFailedException
      Gets a list of auction houses including and under the given auction house node in which any auction can be assigned.
      Parameters:
      auctionHouseId - the Id of the AuctionHouse
      Returns:
      list of assignable auction house Ids
      Throws:
      NullArgumentException - auctionHouseId is null
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • getAssignableAuctionHouseIdsForAuction

      IdList getAssignableAuctionHouseIdsForAuction(Id auctionHouseId, Id auctionId) throws OperationFailedException
      Gets a list of auction houses including and under the given auction house node in which a specific auction can be assigned.
      Parameters:
      auctionHouseId - the Id of the AuctionHouse
      auctionId - the Id of the Auction
      Returns:
      list of assignable auction house Ids
      Throws:
      NullArgumentException - auctionHouseId or auctionId is null
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • assignAuctionToAuctionHouse

      void assignAuctionToAuctionHouse(Id auctionId, Id auctionHouseId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Adds an existing Auction to an AuctionHouse .
      Parameters:
      auctionId - the Id of the Auction
      auctionHouseId - the Id of the AuctionHouse
      Throws:
      AlreadyExistsException - auctionId is already assigned to auctionHouseId
      NotFoundException - auctionId or auctionHouseId not found
      NullArgumentException - auctionId or auctionHouseId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • unassignAuctionFromAuctionHouse

      void unassignAuctionFromAuctionHouse(Id auctionId, Id auctionHouseId) throws NotFoundException, OperationFailedException, PermissionDeniedException
      Removes an Auction from an AuctionHouse .
      Parameters:
      auctionId - the Id of the Auction
      auctionHouseId - the Id of the AuctionHouse
      Throws:
      NotFoundException - auctionId or auctionHouseId not found or auctionId not assigned to auctionHouseId
      NullArgumentException - auctionId or auctionHouseId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • reassignAuctionToAuctionHouse

      void reassignAuctionToAuctionHouse(Id auctionId, Id fromAuctionHouseId, Id toAuctionHouseId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Moves an Auction from one AuctionHouse to another. Mappings to other AuctionHouses are unaffected.
      Parameters:
      auctionId - the Id of the Auction
      fromAuctionHouseId - the Id of the current AuctionHouse
      toAuctionHouseId - the Id of the destination AuctionHouse
      Throws:
      AlreadyExistsException - auctionId already assigned to toAuctionHouseId
      NotFoundException - auctionId, fromAuctionHouseId , or toAuctionHouseId not found or auctionId not mapped to fromAuctionHouseId
      NullArgumentException - auctionId, fromAuctionHouseId , or toAuctionHouseId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.