Class ProductDiscountValueAbsoluteImpl

java.lang.Object
com.commercetools.api.models.product_discount.ProductDiscountValueAbsoluteImpl
All Implemented Interfaces:
ProductDiscountValue, ProductDiscountValueAbsolute, io.vrap.rmf.base.client.ModelBase

public class ProductDiscountValueAbsoluteImpl extends Object implements ProductDiscountValueAbsolute, io.vrap.rmf.base.client.ModelBase

Discounts the Product's Price by a fixed amount, defined by the money field.

  • Constructor Details

  • Method Details

    • getType

      public String getType()
      Specified by:
      getType in interface ProductDiscountValue
      Returns:
      type
    • getMoney

      Money values in different currencies. An absolute ProductDiscount will only match a price if this array contains a value with the same currency. For example, if it contains 10€ and 15$, the matching € price will be decreased by 10€ and the matching $ price will be decreased by 15$.

      Specified by:
      getMoney in interface ProductDiscountValueAbsolute
      Returns:
      money
    • setMoney

      public void setMoney(CentPrecisionMoney... money)
      Description copied from interface: ProductDiscountValueAbsolute

      Money values in different currencies. An absolute ProductDiscount will only match a price if this array contains a value with the same currency. For example, if it contains 10€ and 15$, the matching € price will be decreased by 10€ and the matching $ price will be decreased by 15$.

      Specified by:
      setMoney in interface ProductDiscountValueAbsolute
      Parameters:
      money - values to be set
    • setMoney

      public void setMoney(List<CentPrecisionMoney> money)
      Description copied from interface: ProductDiscountValueAbsolute

      Money values in different currencies. An absolute ProductDiscount will only match a price if this array contains a value with the same currency. For example, if it contains 10€ and 15$, the matching € price will be decreased by 10€ and the matching $ price will be decreased by 15$.

      Specified by:
      setMoney in interface ProductDiscountValueAbsolute
      Parameters:
      money - values to be set
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object