com.ibm.commerce.negotiation.commands
Class AuctionNotificationCmdImpl

com.ibm.commerce.command.AbstractECTargetableCommand
  |
  +--com.ibm.commerce.command.ControllerCommandImpl
        |
        +--com.ibm.commerce.negotiation.commands.AuctionNotificationCmdImpl
All Implemented Interfaces:
AccCommand, AuctionNotificationCmd, ControllerCommand, ECCommand, ECTargetableCommand, Protectable

public class AuctionNotificationCmdImpl
extends ControllerCommandImpl
implements AuctionNotificationCmd

Controller command that drives the auction notification tasks.

Usage:

  1. message type 1 for StartAuctionNotification: expecting msgtype=1&auctid=1234
  2. message type 2 for BidOverrideNotification: expecting msgtype=2&auctid=12345&bidid=12345&bidid=567&bidid=890
  3. message type 3 for WinnerNotification: expecting msgtype=3&auctid=1234&bidid=12345&bidid=4567
  4. message type 4 for CompleteNotification: expecting msgtype=4&auctid=12345b&bidid=38990


Field Summary
protected  AuctionAccessBean auctionAccessBean
           
protected  BidAccessBean[] bidAccessBeanArray
           
protected  java.lang.Integer msgType
           
 
Fields inherited from class com.ibm.commerce.command.ControllerCommandImpl
requestProperties, responseProperties, retriable, viewReqProperties
 
Fields inherited from class com.ibm.commerce.command.AbstractECTargetableCommand
commandContext
 
Fields inherited from interface com.ibm.commerce.negotiation.commands.AuctionNotificationCmd
COPYRIGHT, defaultCommandClassName, NAME
 
Fields inherited from interface com.ibm.commerce.command.ECTargetableCommand
COPYRIGHT
 
Constructor Summary
AuctionNotificationCmdImpl()
          AuctionNotificationCmdImpl default constructor.
 
Method Summary
 AuctionAccessBean getAuctionAccessBean()
          Returns the access bean corresponding to the auction.
 BidAccessBean[] getBidAccessBeanArray()
          Get bid access bean array.
 java.lang.Integer getMsgType()
          Returns the type of the message.
 void initParameters(TypedProperty param)
          Retrieves and validates the parameters from the request.
 void notifyAuctionStart()
          Invoking start auction notification task for the specified auction.
 void notifyAuctionStart(AuctionAccessBean aBean)
          Invoking start auction notification task for the specified auction.
protected  void notifyBidOverride()
          Invoking bid override notification task for the specified bid.
protected  void notifyOrderForSingleBid(BidAccessBean bid)
          Invoking Orders notification task for the specified bid.
protected  void notifyOrders()
          Invoking Orders notification task for the specified auction or bids.
protected  void notifyWinners()
          Invoking winners notification task for the specified auction.
 void performExecute()
          Execute the command.
 void setAuctionAccessBean(AuctionAccessBean newAuctionAccessBean)
          Saves the incoming auction access bean.
 void setBidAccessBeanArray(BidAccessBean[] newBidAccessBeans)
          Set bid access bean array.
 void setMsgType(java.lang.Integer newMsgType)
          Stores the incoming value for the message type.
 void setRequestProperties(TypedProperty reqProperties)
          set request properties and initialize the parameters for the command.
 
Methods inherited from class com.ibm.commerce.command.ControllerCommandImpl
fulfills, getForUserId, getGeneric, getOwner, getRequestProperties, getResolvedRequestProperties, getResponseProperties, getRetriable, getViewInputProperties, isGeneric, isRetriable, mergeProperties, setForUserId, setGeneric, setOwner, setResponseProperties, setRetriable, setViewInputProperties
 
Methods inherited from class com.ibm.commerce.command.AbstractECTargetableCommand
accessControlCheck, checkIsAllowed, checkResourcePermission, execute, finalize, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getDefaultProperties, getResources, getStoreId, getUser, getUserId, isReadyToCallExecute, reset, setAccCheck, setCommandContext, setCommandIfName, setDefaultProperties, validateParameters
 
Methods inherited from interface com.ibm.commerce.command.ControllerCommand
execute, getGeneric, getRequestProperties, getResolvedRequestProperties, getResponseProperties, getRetriable, getViewInputProperties, isGeneric, isRetriable, mergeProperties, setGeneric, setRetriable, setViewInputProperties
 
Methods inherited from interface com.ibm.commerce.command.AccCommand
accessControlCheck, getAccCheck, getForUserId, setAccCheck, setForUserId, setOwner
 
Methods inherited from interface com.ibm.commerce.command.ECCommand
checkIsAllowed, checkResourcePermission, getCommandContext, getCommandIfName, getCommandName, getDefaultProperties, getResources, getStoreId, getUser, getUserId, setCommandContext, setCommandIfName, setDefaultProperties, validateParameters
 
Methods inherited from interface com.ibm.commerce.security.Protectable
fulfills, getOwner
 

Field Detail

auctionAccessBean

protected AuctionAccessBean auctionAccessBean

bidAccessBeanArray

protected BidAccessBean[] bidAccessBeanArray

msgType

protected java.lang.Integer msgType
Constructor Detail

AuctionNotificationCmdImpl

public AuctionNotificationCmdImpl()
AuctionNotificationCmdImpl default constructor.
Method Detail

getAuctionAccessBean

public AuctionAccessBean getAuctionAccessBean()
Returns the access bean corresponding to the auction.
Returns:
The Auction Access Bean

getBidAccessBeanArray

public BidAccessBean[] getBidAccessBeanArray()
Get bid access bean array.
Returns:
Bid access bean array.

getMsgType

public java.lang.Integer getMsgType()
Returns the type of the message.
Returns:
the message type.

initParameters

public void initParameters(TypedProperty param)
                    throws ECApplicationException
Retrieves and validates the parameters from the request.
Parameters:
param - parameters from the request.

notifyAuctionStart

public void notifyAuctionStart()
                        throws ECException
Invoking start auction notification task for the specified auction.

notifyAuctionStart

public void notifyAuctionStart(AuctionAccessBean aBean)
                        throws ECException
Invoking start auction notification task for the specified auction.
Parameters:
aBean - the auction access bean.

notifyBidOverride

protected void notifyBidOverride()
Invoking bid override notification task for the specified bid.

notifyOrderForSingleBid

protected void notifyOrderForSingleBid(BidAccessBean bid)
                                throws ECException
Invoking Orders notification task for the specified bid.

notifyOrders

protected void notifyOrders()
                     throws ECSystemException
Invoking Orders notification task for the specified auction or bids.

notifyWinners

protected void notifyWinners()
                      throws ECException
Invoking winners notification task for the specified auction.

performExecute

public void performExecute()
                    throws ECException
Execute the command.
Specified by:
performExecute in interface ECCommand
Overrides:
performExecute in class AbstractECTargetableCommand
Throws:
ECException. -  

setAuctionAccessBean

public void setAuctionAccessBean(AuctionAccessBean newAuctionAccessBean)
Saves the incoming auction access bean.
Parameters:
newAuctionAccessBean -  

setBidAccessBeanArray

public void setBidAccessBeanArray(BidAccessBean[] newBidAccessBeans)
Set bid access bean array.
Parameters:
the - bid access bean list.

setMsgType

public void setMsgType(java.lang.Integer newMsgType)
Stores the incoming value for the message type.
Parameters:
newMsgType -  

setRequestProperties

public void setRequestProperties(TypedProperty reqProperties)
                          throws ECException
set request properties and initialize the parameters for the command.
Specified by:
setRequestProperties in interface ControllerCommand
Overrides:
setRequestProperties in class ControllerCommandImpl
Parameters:
requestProperties -  
Throws:
If - anything goes wrong.