public class DefaultReward extends java.lang.Object implements Reward
<p> <Reward impl="com.ibm.commerce.marketing.promotion.reward.DefaultReward"> <!-- Multiple AdjustmentFunctions can be specified --> <AdjustmentFunction impl="com.ibm.commerce.marketing.promotion.reward.AdjustmentFunction"> <FilterChain impl="com.ibm.commerce.marketing.promotion.condition.FilterChain"> <!-- Multiple Filters can be specified --> <Filter></Filter> </FilterChain> <Adjustment></Adjustment> </AdjustmentFunction> </Reward> </p>
Modifier and Type | Field and Description |
---|---|
static java.lang.String | COPYRIGHT
IBM copyright notice field.
|
static java.lang.String | REWARD_POLICY_ALL
The reward is qualified only if all defined AdjustmentFunctions apply.
|
static java.lang.String | REWARD_POLICY_ANY
The reward is qualified if any AdjustmentFunctions applies.
|
Constructor and Description |
---|
DefaultReward()
Constructor for DefaultReward.
|
Modifier and Type | Method and Description |
---|---|
boolean | computeReward(PromotionContext context, PromotionExecutionRecord record)
computeReward method applies the adjustments to the targeted line items.
|
void | fromXML(org.w3c.dom.Node anXMLNode)
Transforms the XML node into its corresponding real Object.
|
AdjustmentFunction[] | getAdjustmentFunctions()
This method gets the list of AdjustmentFunction for this Reward.
|
java.lang.String | getRewardPolicy()
Gets the reward policy value.
|
void | setAdjustmentFunctions(AdjustmentFunction[] adjustmentList)
This method sets the list of AdjustmentFunction for this Reward.
|
void | setRewardPolicy(java.lang.String rewardPolicy)
Sets the reward policy value.
|
java.lang.String | toXML()
Converts the object into its corresponding XML format representation.
|
public static final java.lang.String COPYRIGHT
public static final java.lang.String REWARD_POLICY_ALL
public static final java.lang.String REWARD_POLICY_ANY
public AdjustmentFunction[] getAdjustmentFunctions()
public void setAdjustmentFunctions(AdjustmentFunction[] adjustmentList)
public boolean computeReward(PromotionContext context, PromotionExecutionRecord record) throws PromotionRewardCalcuationException
public java.lang.String toXML() throws XMLizationException
public void fromXML(org.w3c.dom.Node anXMLNode) throws DeXMLizationException
public java.lang.String getRewardPolicy()
public void setRewardPolicy(java.lang.String rewardPolicy)