public class DetermineWinnersCmdImpl extends TaskCommandImpl implements DetermineWinnersCmd, com.ibm.commerce.negotiation.util.AuctionConstants
Modifier and Type | Field and Description |
---|---|
static java.lang.String | COPYRIGHT
IBM copyright notice field.
|
protected java.util.Vector | winners
A list of auto bids that are winning.
|
Constructor and Description |
---|
DetermineWinnersCmdImpl()
DetermineWinnersCmdImpl default constructor.
|
Modifier and Type | Method and Description |
---|---|
protected java.math.BigDecimal | calculateNextBidValue(java.math.BigDecimal currMaxBidValue)
Calculates the next bid value based on the current maximum bid value and the bid rule range/increment.
|
protected com.ibm.commerce.negotiation.objimpl.BidDataLight | findNextLoser(int start, double availQuant)
Given the index of a winning auto bid, to find the closest loser(the runner-up).
|
protected java.util.Vector | getActiveBids()
Gets the list of active bids for processing.
|
protected ControlRuleAccessBean | getBidRule()
A singleton method for retrieving Control Rule Access Bean.
|
protected java.lang.Long | getBidRuleId()
Gets the auction's bid rule ID.
|
protected java.math.BigDecimal | getDefaultBidIncrement()
Returns a default bid increment value.
|
protected java.math.BigDecimal | getDefaultMinBidValue()
Returns a default minimum bid value.
|
protected java.lang.String | getErrorTaskName()
Returns error task name that will be returned by the exceptions.
|
protected java.lang.Double | getQuantityOnAuction()
Gets the quantity available for auction.
|
java.util.Vector | getWinners()
Gets the list of auto bids that are winning.
|
protected void | handleException(java.lang.Exception e)
Formats an ECException based on the input exception value.
|
boolean | isReadyToCallExecute()
Verifies that the this command is ready to be executed.
|
void | performExecute()
For all active auto bids.
|
void | reset()
Resets this command to allow for future reuse.
|
void | setActiveBids(java.util.Vector bids)
Sets the list of active bids to be processed.
|
void | setBidRuleId(java.lang.Long id)
Sets the auction Bid rule ID
|
void | setErrorTaskName(java.lang.String errorTaskName)
Sets error task name that will be returned by the exceptions.
|
void | setQuantityOnAuction(java.lang.Double quantity)
Sets the quantity available for auction.
|
void | setWinners(java.util.Vector newWinners)
Sets the list of autobids that are currently winning.
|
static java.lang.String | traceBid(com.ibm.commerce.negotiation.objimpl.BidDataLight bid)
Returns a string that shows the information about a bid.
|
public static final java.lang.String COPYRIGHT
protected java.util.Vector winners
public DetermineWinnersCmdImpl()
protected java.math.BigDecimal calculateNextBidValue(java.math.BigDecimal currMaxBidValue) throws ECException
protected com.ibm.commerce.negotiation.objimpl.BidDataLight findNextLoser(int start, double availQuant)
protected java.util.Vector getActiveBids()
protected ControlRuleAccessBean getBidRule() throws java.lang.Exception
protected java.lang.Long getBidRuleId()
protected java.math.BigDecimal getDefaultBidIncrement()
protected java.math.BigDecimal getDefaultMinBidValue()
protected java.lang.String getErrorTaskName()
protected java.lang.Double getQuantityOnAuction()
public java.util.Vector getWinners()
protected void handleException(java.lang.Exception e) throws ECException
public boolean isReadyToCallExecute()
public void performExecute() throws ECException
public void reset()
public void setActiveBids(java.util.Vector bids)
public void setBidRuleId(java.lang.Long id)
public void setErrorTaskName(java.lang.String errorTaskName)
public void setQuantityOnAuction(java.lang.Double quantity)
public void setWinners(java.util.Vector newWinners)
public static java.lang.String traceBid(com.ibm.commerce.negotiation.objimpl.BidDataLight bid)