com.elasticpath.domain.rules
Interface RuleAction

All Superinterfaces:
EpDomain, Persistence, RuleElement, java.io.Serializable, ValueObject
All Known Implementing Classes:
AbstractRuleActionImpl, CartCategoryAmountDiscountActionImpl, CartCategoryPercentDiscountActionImpl, CartNFreeSkusActionImpl, CartNthProductPercentDiscountActionImpl, CartProductAmountDiscountActionImpl, CartProductPercentDiscountActionImpl, CartSkuAmountDiscountActionImpl, CartSkuPercentDiscountActionImpl, CartSubtotalAmountDiscountActionImpl, CartSubtotalDiscountActionImpl, CartSubtotalPercentDiscountActionImpl, CatalogSkuAmountDiscountActionImpl, CatalogSkuPercentDiscountActionImpl, ProductAmountDiscountActionImpl, ProductPercentDiscountActionImpl, ShippingAmountDiscountActionImpl, ShippingPercentDiscountActionImpl

public interface RuleAction
extends RuleElement

Represents an action that can be executed by a rule.


Field Summary
static java.lang.String ACTION_KIND
          Identifies the RuleElement as an action to a rule.
static java.lang.String DEFAULT_AGENDA_GROUP
          Default agenda group.
static java.lang.String SUBTOTAL_DEPENDENT_AGENDA_GROUP
          Agenda group that identifies actions that must be fired separately because they depend on the post-rule value of the cart subtotal.
 
Method Summary
 java.lang.String getAgendaGroup()
          Get the agenda group for this action.
 int getSalience()
          Get the salience value for this rule.
 void setAgendaGroup(java.lang.String agendaGroup)
          Set the agenda group.
 void setSalience(int salience)
          Set the salience value.
 
Methods inherited from interface com.elasticpath.domain.rules.RuleElement
addParameter, appliesInScenario, getAllowedExceptions, getDisplayText, getExceptions, getKind, getParameterKeys, getParameters, getRuleCode, getType, setExceptions, setKind, setParameters, setRuleId, setType, validate
 
Methods inherited from interface com.elasticpath.domain.Persistence
executeBeforePersistAction, getUidPk, isPersistent, setDefaultValues, setUidPk
 
Methods inherited from interface com.elasticpath.domain.EpDomain
getElasticPath, setElasticPath
 

Field Detail

ACTION_KIND

static final java.lang.String ACTION_KIND
Identifies the RuleElement as an action to a rule.

See Also:
Constant Field Values

DEFAULT_AGENDA_GROUP

static final java.lang.String DEFAULT_AGENDA_GROUP
Default agenda group.

See Also:
Constant Field Values

SUBTOTAL_DEPENDENT_AGENDA_GROUP

static final java.lang.String SUBTOTAL_DEPENDENT_AGENDA_GROUP
Agenda group that identifies actions that must be fired separately because they depend on the post-rule value of the cart subtotal.

See Also:
Constant Field Values
Method Detail

getAgendaGroup

java.lang.String getAgendaGroup()
Get the agenda group for this action. The agenda group is used to determine which rules will be fired together.
Only one action in a given rule can specify an agenda group because the group will become the agenda group of the rule

Returns:
the agenda group or null if no agenda group is required

getSalience

int getSalience()
Get the salience value for this rule. The higher the salience, the earlier the actions of the rule will be executed relative to other rules.

Returns:
the salience value

setAgendaGroup

void setAgendaGroup(java.lang.String agendaGroup)
Set the agenda group.

Parameters:
agendaGroup - the agenda group name
See Also:
getAgendaGroup

setSalience

void setSalience(int salience)
Set the salience value.

Parameters:
salience - the new salience value
See Also:
getSalience