public class CheckValidityCmdImpl extends TaskCommandImpl implements CheckValidityCmd
The purpose of this command is to check each of the eCoupons for expiry and put the information in expired variable which is used by the calling commands.
For each cpwalletId the cppmnId is found out. Then the endDate is found out corresponding to this coupon promotion and if this endDate is after the current time, the coupon is not expired. These above steps are performed for each cpwalletId. This command uses CouponWalletAccessBean and CouponPromotionAccessBean.
Modifier and Type | Field and Description |
---|---|
protected java.lang.Long[] | bcIds
Deprecated.
The IDs of the coupons to be applied to this order
|
protected java.sql.Timestamp | currentTimeStamp
Deprecated.
The current system time.
|
protected TypedProperty | inParam
Deprecated.
The request properties.
|
protected TypedProperty | outParam
Deprecated.
The response properties.
|
protected TypedProperty | reqParam
Deprecated.
The request properties.
|
protected boolean[] | validCoupons
Deprecated.
The nth element denotes if the nth coupon is applicable.
|
Constructor and Description |
---|
CheckValidityCmdImpl()
Deprecated.
CheckValidityCmdImpl constructor, call super.
|
Modifier and Type | Method and Description |
---|---|
java.lang.Long[] | getBcIds()
Deprecated.
Gets the eCoupon IDs.
|
java.sql.Timestamp | getCurrentTimeStamp()
Deprecated.
Gets the current timestamp.
|
TypedProperty | getRequestProperties()
Deprecated.
Gets the request properties.
|
TypedProperty | getResponseProperties()
Deprecated.
Gets the response properties.
|
boolean[] | getValidCoupons()
Deprecated.
Gets the array indicating whether the Coupons are valid or not.
|
void | performExecute()
Deprecated.
For each cpwalletId the cppmnId is found out.
|
void | setBcIds(java.lang.Long[] newBcIds)
Deprecated.
Sets eCoupon IDs.
|
void | setCurrentTimeStamp(java.sql.Timestamp newCurrentTimeStamp)
Deprecated.
Sets current time.
|
void | setRequestProperties(TypedProperty param)
Deprecated.
Sets the request properties.
|
void | setValidCoupons(boolean[] newValidCoupons)
Deprecated.
Sets valid eCoupons.
|
void | validateParameters()
Deprecated.
Checks the parameters.
|
protected TypedProperty outParam
protected TypedProperty reqParam
protected java.lang.Long[] bcIds
protected java.sql.Timestamp currentTimeStamp
protected TypedProperty inParam
protected boolean[] validCoupons
public CheckValidityCmdImpl()
public java.lang.Long[] getBcIds()
public java.sql.Timestamp getCurrentTimeStamp()
public TypedProperty getRequestProperties()
public TypedProperty getResponseProperties()
public boolean[] getValidCoupons()
public void performExecute() throws ECException
For each cpwalletId the cppmnId is found out. Then the endDate is found out corresponding to this coupon promotion and if this endDate is after the current time, the coupon is not expired. These above steps are performed for each cpwalletId.
public void setBcIds(java.lang.Long[] newBcIds)
public void setCurrentTimeStamp(java.sql.Timestamp newCurrentTimeStamp)
public void setRequestProperties(TypedProperty param)
public void setValidCoupons(boolean[] newValidCoupons)
public void validateParameters() throws ECException