|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
com.ibm.commerce.payment.commands.DoDepositPMCmdImpl
This CheckPaymentAcceptPolicy
business policy
command implementation class is the default implementation class
for depositing the payment previously authorized by WebSphere Payment Manager.
Parameter:
Parameter Name | Type | Descriptions |
order | OrderAccessBean | The Order Access Bean |
depositAmount | BigDecimal | The amount of the deposit |
errorViewName | String | Optional error view name passed in by the Caller. |
PaymentConstants.ERR_CODE_PM_COMM_ERR
(1950)
- Communication to Payment System failed. (Connection to Payment Manager Failed.)
PaymentConstants.ERR_CODE_ORDER_UNKNOWN
(1951)
- Order is not known to the Payment System (Order does not exist as a Payment Manager Order.)
PaymentConstants.ERR_CODE_PM_REJECTED
(1952)
- Payment System rejected the command due to error. (WebSphere Payment Manager Operation "p" for StoreId "s" OrderId "m" failed. WebSphere Payment Manager PrimaryRC=x, SecondaryRC=y.)
Field Summary | |
static java.lang.String |
PAYMENT_NUMBER
|
Fields inherited from interface com.ibm.commerce.payment.commands.DoDepositPolicyCmd |
COPYRIGHT, defaultCommandClassName, ERRTASK_NAME, NAME |
Constructor Summary | |
DoDepositPMCmdImpl()
|
Method Summary | |
protected void |
convertAmountToStoreDefaultCurrency(java.lang.Long nOrderId)
This is called by performExecute to convert the Amount to the Store Default Currency |
protected java.lang.String |
getBuyerLanguageId()
Get the LanguageId of the Buyer. |
protected java.math.BigDecimal |
getChargeAmount()
Retrieve Charge Amount |
protected java.lang.Double |
getCurrencyFactor()
Retrieve Currency Factor |
java.math.BigDecimal |
getDepositAmount()
Retrieve Deposit Amount |
protected java.lang.String |
getErrorViewName()
Retrieve the error view name passed in by the Caller. |
protected OrderAccessBean |
getOrder()
Retrieve Order |
protected java.lang.String |
getStoreDefaultCurrency()
Retrieve Store Default Currency |
boolean |
isReadyToCallExecute()
This method is called by the Command Framework to check if all basic mandatory parameters have been set for this command. |
void |
performExecute()
Performs the main business logic of the command. |
java.util.Hashtable |
query(java.lang.String queryString)
The Cashier calls this method to construct a Hashtable of keywords and values which result from processing the input query string. |
void |
reset()
Resets the instance variables of the command. |
protected void |
setChargeAmount(java.math.BigDecimal n)
Set Charge Amount |
protected void |
setCurrencyExponent(java.lang.String astrCurrencyExponent)
Store Currency Exponent |
protected void |
setCurrencyFactor(java.lang.Double d)
Store Currency Factor |
void |
setDepositAmount(java.math.BigDecimal depositAmount)
Sets the depositAmount property of the command. |
void |
setErrorViewName(java.lang.String sEVN)
Optional error view name passed in by the Caller. |
protected void |
setNumericCurrencyCode(java.lang.String astrCurrencyCode)
Set Numeric Currency Code |
void |
setOrder(OrderAccessBean ab)
The order to be deposited. |
protected void |
setPMDepositAmount(java.math.BigInteger depositAmount)
Set Deposit Amount for WebSphere Payment Manager |
protected void |
setStoreDefaultCurrency(java.lang.String s)
Set Store Default Currency |
protected void |
setupNumericCurrencyCodeAndPMDepositAmount()
This is called by performExecute to retrieve WebSphere Payment Manager ready amount |
protected void |
updateOrderPaymentMethod()
This is called by performExecute to update ORDPAYMTHD table with deposit info |
Methods inherited from interface com.ibm.commerce.command.BusinessPolicyCommand |
getPolicyId, getRequestProperties, setPolicyId, setRequestProperties |
Methods inherited from interface com.ibm.commerce.command.ECCommand |
checkIsAllowed, checkResourcePermission, execute, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getDefaultProperties, getResources, getStoreId, getUser, getUserId, setAccCheck, setCommandContext, setCommandIfName, setDefaultProperties, validateParameters |
Field Detail |
public static final java.lang.String PAYMENT_NUMBER
Constructor Detail |
public DoDepositPMCmdImpl()
Method Detail |
protected void convertAmountToStoreDefaultCurrency(java.lang.Long nOrderId) throws javax.ejb.CreateException, javax.ejb.FinderException, javax.naming.NamingException, java.rmi.RemoteException, ECException
protected java.lang.String getBuyerLanguageId() throws javax.ejb.CreateException, javax.ejb.FinderException, javax.naming.NamingException, java.rmi.RemoteException
protected java.math.BigDecimal getChargeAmount()
protected java.lang.Double getCurrencyFactor()
public java.math.BigDecimal getDepositAmount()
protected java.lang.String getErrorViewName()
protected OrderAccessBean getOrder()
protected java.lang.String getStoreDefaultCurrency()
public boolean isReadyToCallExecute()
public void performExecute() throws ECException
performExecute
in interface ECCommand
com.ibm.commerce.command.ECCommand
com.ibm.commerce.command.CommandException
- The superclass for all ECExceptions.public java.util.Hashtable query(java.lang.String queryString) throws com.ibm.commerce.payment.commands.CashierException
This method is defined by the com.ibm.etill.cashier.Queryable interface.
queryString
- a SelectStatement element from a Cashier profilecom.ibm.commerce.payment.commands.CashierException
- if there is an error creating and populating the
result Hashtable.public void reset()
This is useful if the command instance is to be called multiple times with different command parameters.
protected void setChargeAmount(java.math.BigDecimal n)
protected void setCurrencyExponent(java.lang.String astrCurrencyExponent)
protected void setCurrencyFactor(java.lang.Double d)
public void setDepositAmount(java.math.BigDecimal depositAmount)
DoDepositPolicyCmd
setDepositAmount
in interface DoDepositPolicyCmd
com.ibm.commerce.payment.commands.DoDepositPolicyCmd
depositAmount
- the amount to be deposited.public void setErrorViewName(java.lang.String sEVN)
setErrorViewName
in interface DoDepositPolicyCmd
protected void setNumericCurrencyCode(java.lang.String astrCurrencyCode)
public void setOrder(OrderAccessBean ab)
setOrder
in interface DoDepositPolicyCmd
com.ibm.commerce.payment.commands.DoDepositPolicyCmd
abOrder
- the OrderAccessBean of the Order for which
is going to be deposited.protected void setPMDepositAmount(java.math.BigInteger depositAmount)
protected void setStoreDefaultCurrency(java.lang.String s)
protected void setupNumericCurrencyCodeAndPMDepositAmount() throws javax.ejb.CreateException, javax.ejb.FinderException, javax.naming.NamingException, java.rmi.RemoteException, ECException
protected void updateOrderPaymentMethod() throws javax.ejb.CreateException, javax.ejb.FinderException, javax.naming.NamingException, java.rmi.RemoteException
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |