public class PromoCodeLoader
extends java.lang.Object
Constructor and Description |
---|
PromoCodeLoader() |
Modifier and Type | Method and Description |
---|---|
static void | cleanCodeLoaderForPromotion(java.lang.String promotionId)
Clean the related code loader free for GC
|
static PromoCodeLoader | getCodeLoaderForPromotion(java.lang.String promotionId)
Get the promotionId related code loader
|
java.lang.String | getFileUploadId()
Get file upload id
|
java.lang.String[] | getNextBatchCodes()
This method will get a batch of the codes and the return String array size will be the Minimum of targetTotal and batchSize
|
java.lang.String | getProcessFileId()
get process file id
|
java.lang.Long | getTargetTotal()
Get the total number of the generated codes
|
void | setBatchSize(int localBatchSize)
Set batch size
|
static void | setCodeLoaderForPromotion(java.lang.String promotionId, PromoCodeLoader cl)
Put the code loader to cache
|
void | setFileUploadId(java.lang.String newFileUploadId)
set file upload id
|
void | setProcessFileId(java.lang.String newProcessFileId)
set process file id
|
void | setPromotionCodes(java.lang.String[] newPromotionCodes)
This method is used to set promotion codes.
|
void | setTargetTotal(java.lang.Long target)
Set the total number of generate codes
|
public void setPromotionCodes(java.lang.String[] newPromotionCodes)
public void setTargetTotal(java.lang.Long target)
public java.lang.Long getTargetTotal()
public void setBatchSize(int localBatchSize)
public java.lang.String getFileUploadId()
public void setFileUploadId(java.lang.String newFileUploadId)
public java.lang.String getProcessFileId()
public void setProcessFileId(java.lang.String newProcessFileId)
public static PromoCodeLoader getCodeLoaderForPromotion(java.lang.String promotionId)
public static void setCodeLoaderForPromotion(java.lang.String promotionId, PromoCodeLoader cl)
public static void cleanCodeLoaderForPromotion(java.lang.String promotionId)
public java.lang.String[] getNextBatchCodes()