Interface CommercePromotionFacade
-
- All Known Implementing Classes:
DefaultCommercePromotionFacade
public interface CommercePromotionFacadePromotion facade interface. Its main purpose is to retrieve promotion related DTOs using existing services.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.List<PromotionData>getOrderPromotions()Get the list of order promotionsjava.util.List<PromotionData>getOrderPromotions(java.lang.String promotionGroup)Get list of order promotion instances that belong to given promotion groupjava.util.List<PromotionData>getOrderPromotions(java.util.Collection<java.lang.String> promotionGroups)Get list of order promotion instances that belong to one of given promotion groupsjava.util.List<PromotionData>getProductPromotions()Get the list of product promotionsjava.util.List<PromotionData>getProductPromotions(java.lang.String promotionGroup)Get list of product promotions that belong to given promotion groupjava.util.List<PromotionData>getProductPromotions(java.util.Collection<java.lang.String> promotionGroups)Get list of product promotions that belong to one of given promotion groupsPromotionDatagetPromotion(java.lang.String code)Get promotion base on its codePromotionDatagetPromotion(java.lang.String code, java.util.Collection<PromotionOption> options)Get promotion base on its code
-
-
-
Method Detail
-
getProductPromotions
java.util.List<PromotionData> getProductPromotions()
Get the list of product promotions- Returns:
- The list of product promotions
-
getOrderPromotions
java.util.List<PromotionData> getOrderPromotions()
Get the list of order promotions- Returns:
- The list of
OrderPromotionModel
-
getProductPromotions
java.util.List<PromotionData> getProductPromotions(java.util.Collection<java.lang.String> promotionGroups)
Get list of product promotions that belong to one of given promotion groups- Parameters:
promotionGroups- The promotion groups to evaluate- Returns:
- The list of product promotions
- Throws:
java.lang.IllegalArgumentException- - if parameter promotionGroups isnullOR promotionGroups is empty OR any of promotion group from collection doesn't exists
-
getProductPromotions
java.util.List<PromotionData> getProductPromotions(java.lang.String promotionGroup)
Get list of product promotions that belong to given promotion group- Parameters:
promotionGroup- The promotion group to evaluate- Returns:
- The list of product promotions
- Throws:
java.lang.IllegalArgumentException- - if parameter promotionGroup isnullOR promotionGroup doesn't exists
-
getOrderPromotions
java.util.List<PromotionData> getOrderPromotions(java.util.Collection<java.lang.String> promotionGroups)
Get list of order promotion instances that belong to one of given promotion groups- Parameters:
promotionGroups- The promotion groups to evaluate- Returns:
- The list of order promotion
- Throws:
java.lang.IllegalArgumentException- - if parameter promotionGroups isnullOR promotionGroups is empty OR any of promotion group from collection doesn't exists
-
getOrderPromotions
java.util.List<PromotionData> getOrderPromotions(java.lang.String promotionGroup)
Get list of order promotion instances that belong to given promotion group- Parameters:
promotionGroup- The promotion group to evaluate- Returns:
- The list of order promotion
- Throws:
java.lang.IllegalArgumentException- - if parameter promotionGroup isnullOR promotionGroup doesn't exists
-
getPromotion
PromotionData getPromotion(java.lang.String code)
Get promotion base on its code- Parameters:
code- - promotion identifier- Returns:
- the
PromotionData - Throws:
UnknownIdentifierException- if no Promotion with the specified code is foundAmbiguousIdentifierException- if more than one Promotion with the specified code is foundjava.lang.IllegalArgumentException- if parameter code isnull
-
getPromotion
PromotionData getPromotion(java.lang.String code, java.util.Collection<PromotionOption> options)
Get promotion base on its code- Parameters:
code- - promotion identifieroptions- - options set that determines amount of information that will be attached to the returned promotion. BASIC informations are attached by default- Returns:
- the
PromotionData - Throws:
UnknownIdentifierException- if no Promotion with the specified code is foundAmbiguousIdentifierException- if more than one Promotion with the specified code is foundjava.lang.IllegalArgumentException- if parameter code isnull
-
-