Class LivePriceGridAction<ATTACHEDTO extends Help>
- Object
-
- Action
-
- LivePriceGridAction<ATTACHEDTO>
-
- All Implemented Interfaces:
Help
public class LivePriceGridAction<ATTACHEDTO extends Help> extends ActionThis action starts calculation of selected LPG for all skus or restricted set of skus. It's a programmatic version of the same action available in UI. As such it allows user to schedule the action in calculation flow formula.
-
-
Constructor Summary
Constructors Constructor Description LivePriceGridAction(ATTACHEDTO backLink, Invocations<MethodInvocationRecord> invocations, String livePriceGridLabel)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ATTACHEDTOback()BooleangetCalculate()intgetDistributedCalculationThreshold()StringgetLivePriceGridLabel()List<ChainedJobInfo>getNextJobs()StringgetObjectName()intgetPriority()List<String>getRestrictToSkus()LivePriceGridAction<ATTACHEDTO>restrictToSkus(List<String> skus)Restricts LPG calculation to list of presented skusLivePriceGridAction<ATTACHEDTO>setCalculate(Boolean calculate)Whether the action is valid and should be triggered or not.LivePriceGridAction<ATTACHEDTO>setDistributedCalculationThreshold(int threshold)Sets a job-individual threshold to start a distributed calculation.LivePriceGridAction<ATTACHEDTO>setNextJobs(List<ChainedJobInfo> jobs)Defines subsequent follow-on jobsLivePriceGridAction<ATTACHEDTO>setPriority(int priority)Sets the prority of this job.StringtoString()
-
-
-
Constructor Detail
-
LivePriceGridAction
public LivePriceGridAction(ATTACHEDTO backLink, Invocations<MethodInvocationRecord> invocations, String livePriceGridLabel)
-
-
Method Detail
-
setCalculate
public LivePriceGridAction<ATTACHEDTO> setCalculate(Boolean calculate)
Whether the action is valid and should be triggered or not.- Parameters:
calculate-- true - calculation of the LPG is started as background process
- false - calculation of the LPG is NOT started at all
-
setPriority
public LivePriceGridAction<ATTACHEDTO> setPriority(int priority)
Sets the prority of this job.- Parameters:
priority- Default is 0 (lowest user-definable priority). Max value is 9.- Returns:
-
setDistributedCalculationThreshold
public LivePriceGridAction<ATTACHEDTO> setDistributedCalculationThreshold(int threshold)
Sets a job-individual threshold to start a distributed calculation. Please note: Any values below 1000 may very well be counter-productive and make the job slower!- Parameters:
threshold- The number of items that need to be part of the job in order to execute it in distributed mode.- Returns:
-
restrictToSkus
public LivePriceGridAction<ATTACHEDTO> restrictToSkus(List<String> skus)
Restricts LPG calculation to list of presented skus- Parameters:
skus- list of skus to process.s
-
back
public ATTACHEDTO back()
-
setNextJobs
public LivePriceGridAction<ATTACHEDTO> setNextJobs(List<ChainedJobInfo> jobs)
Defines subsequent follow-on jobs- Parameters:
jobs- List of ChainedJobInfo objects- Returns:
-
getObjectName
public String getObjectName()
-
getLivePriceGridLabel
public String getLivePriceGridLabel()
-
getCalculate
public Boolean getCalculate()
-
getPriority
public int getPriority()
-
getDistributedCalculationThreshold
public int getDistributedCalculationThreshold()
-
getNextJobs
public List<ChainedJobInfo> getNextJobs()
-
-