|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object atg.nucleus.logging.VariableArgumentApplicationLoggingImpl atg.nucleus.GenericService atg.commerce.payment.GiftCertificateProcessorImpl
public class GiftCertificateProcessorImpl
This class performs the actual functions of authorizing, debiting and crediting a giftcertificate. These are all the method that must be implemented in order to provide a payment method.
Field Summary | |
---|---|
static java.lang.String |
CLASS_VERSION
|
Fields inherited from class atg.nucleus.GenericService |
---|
SERVICE_INFO_KEY |
Fields inherited from interface atg.nucleus.logging.TraceApplicationLogging |
---|
DEFAULT_LOG_TRACE_STATUS |
Fields inherited from interface atg.nucleus.logging.ApplicationLogging |
---|
DEFAULT_LOG_DEBUG_STATUS, DEFAULT_LOG_ERROR_STATUS, DEFAULT_LOG_INFO_STATUS, DEFAULT_LOG_WARNING_STATUS |
Constructor Summary | |
---|---|
GiftCertificateProcessorImpl()
|
Method Summary | |
---|---|
GiftCertificateStatus |
authorize(GiftCertificateInfo pGiftCertificateInfo)
The authorizaton of a gift certificate calls the authorizeClaimableGiftCerificate method in the ClaimableManager. |
GiftCertificateStatus |
credit(GiftCertificateInfo pGiftCertificateInfo)
Credit the gift certificate identified with the parameter pGiftCertificateInfo.getGiftCertificateNumber() the amount returned by the getAmount call on the same giftCertificateInfo parameter. |
GiftCertificateStatus |
credit(GiftCertificateInfo pGiftCertificateInfo,
PaymentStatus pStatus)
Credit the gift certificate identified with the parameter pGiftCertificateInfo.getGiftCertificateNumber() the amount returned by the getAmount call on the same giftCertificateInfo parameter. |
GiftCertificateStatus |
debit(GiftCertificateInfo pGiftCertificateInfo,
PaymentStatus pStatus)
We check to see if the PaymentStatus amount is greater that the amount indicated in the giftCertificateInfo. |
GiftCertificateStatus |
decreaseAuthorization(GiftCertificateInfo pGiftCertificateInfo,
PaymentStatus pAuthStatus)
|
GiftCertificateStatus |
expireAuthorization(GiftCertificateInfo pGiftCertificateInfo)
Expire a gift certificate authorization |
ClaimableManager |
getClaimableManager()
Get the ClaimableManager property. |
protected java.lang.String |
getNextTransactionId()
This method generates a transactionId by returning a the System time in milliseconds. |
long |
getSecondsUntilExpiration()
Returns property secondsUntilExpiration |
void |
setClaimableManager(ClaimableManager pClaimableManager)
Set the ClaimableManager that will be used to claim the gift certificats. |
void |
setSecondsUntilExpiration(long pSecondsUntilExpiration)
Sets property secondsUntilExpiration |
Methods inherited from class atg.nucleus.logging.VariableArgumentApplicationLoggingImpl |
---|
vlogDebug, vlogDebug, vlogDebug, vlogDebug, vlogDebugTrace, vlogError, vlogError, vlogError, vlogError, vlogInfo, vlogInfo, vlogInfo, vlogInfo, vlogTrace, vlogTrace, vlogTrace, vlogTrace, vlogWarning, vlogWarning, vlogWarning, vlogWarning |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static java.lang.String CLASS_VERSION
Constructor Detail |
---|
public GiftCertificateProcessorImpl()
Method Detail |
---|
public void setClaimableManager(ClaimableManager pClaimableManager)
pClaimableManager
- the ClaimableManager that will be usedpublic ClaimableManager getClaimableManager()
public long getSecondsUntilExpiration()
public void setSecondsUntilExpiration(long pSecondsUntilExpiration)
pSecondsUntilExpiration
- the value to set for property secondsUntilExpirationprotected java.lang.String getNextTransactionId()
public GiftCertificateStatus authorize(GiftCertificateInfo pGiftCertificateInfo)
authorize
in interface GiftCertificateProcessor
pGiftCertificateInfo
- the GiftCertificateInfo reference which contains all the
authorization data
public GiftCertificateStatus expireAuthorization(GiftCertificateInfo pGiftCertificateInfo)
expireAuthorization
in interface GiftCertificateProcessor
pGiftCertificateInfo
- the GiftCertificateInfo reference which contains all the authorization expiration data
public GiftCertificateStatus debit(GiftCertificateInfo pGiftCertificateInfo, PaymentStatus pStatus)
debit
in interface GiftCertificateProcessor
pGiftCertificateInfo
- the GiftCertificateInfo reference which contains all the debit
datapStatus
- the PaymentStatus object which contains information about the transaction.
This should be the object which was returned from authorize().
public GiftCertificateStatus credit(GiftCertificateInfo pGiftCertificateInfo, PaymentStatus pStatus)
credit
in interface GiftCertificateProcessor
pGiftCertificateInfo
- the GiftCertificateInfo reference which contains all the credit datapStatus
- the PaymentStatus object which contains information about the transaction. This
should be the object which was returned from debit().
public GiftCertificateStatus credit(GiftCertificateInfo pGiftCertificateInfo)
credit
in interface GiftCertificateProcessor
pGiftCertificateInfo
- the GiftCertificateInfo reference which contains all the credit data
public GiftCertificateStatus decreaseAuthorization(GiftCertificateInfo pGiftCertificateInfo, PaymentStatus pAuthStatus)
decreaseAuthorization
in interface atg.payment.giftcertificate.DecreaseGiftCertificateAuthorizationProcessor
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |