Interface RuleActionStrategy<T extends ItemModel>
-
- All Known Implementing Classes:
AbstractRuleActionStrategy,DefaultAddCouponActionStrategy,DefaultAddProductToCartActionStrategy,DefaultNoOpRuleActionStrategy,DefaultOrderAdjustTotalActionStrategy,DefaultOrderEntryAdjustActionStrategy,DefaultPotentialPromotionMessageActionStrategy,DefaultShippingActionStrategy
public interface RuleActionStrategy<T extends ItemModel>Defines a strategy that encapsulates the logic of a rule action.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.List<T>apply(AbstractRuleActionRAO action)Applies the action described by the givenAbstractRuleActionRAO.java.lang.StringgetStrategyId()Returns this strategy's unique Idvoidundo(ItemModel action)Revokes the Promotion Action that was applied.
-
-
-
Method Detail
-
apply
java.util.List<T> apply(AbstractRuleActionRAO action)
Applies the action described by the givenAbstractRuleActionRAO.- Parameters:
action- the action to apply- Returns:
- list of
ItemModelthat are affected by the application of this action.
-
getStrategyId
java.lang.String getStrategyId()
Returns this strategy's unique Id- Returns:
- the strategy's Id
-
undo
void undo(ItemModel action)
Revokes the Promotion Action that was applied.- Parameters:
action- the action to be undone
-
-