Class EarningRuleLoyaltyOrderMetadata

java.lang.Object
io.voucherify.client.model.EarningRuleLoyaltyOrderMetadata

@Generated("org.openapitools.codegen.languages.JavaClientCodegen") public class EarningRuleLoyaltyOrderMetadata extends Object
Defines the ratio based on the property defined in the calculation_type parameter. For every given increment of value (1, 10, etc) defined in the every parameter for the property defined in calculation_type, give the customer the number of points defined in the points parameter. In other words, for every order metadata property value, give points.
  • Field Details

  • Constructor Details

    • EarningRuleLoyaltyOrderMetadata

      public EarningRuleLoyaltyOrderMetadata()
  • Method Details

    • every

    • getEvery

      @Nullable public Integer getEvery()
      For how many increments of the order metadata property to grant points for.
      Returns:
      every
    • setEvery

      public void setEvery(Integer every)
    • points

      public EarningRuleLoyaltyOrderMetadata points(Integer points)
    • getPoints

      @Nullable public Integer getPoints()
      Number of points to be awarded, i.e. how many points to be added to the loyalty card.
      Returns:
      points
    • setPoints

      public void setPoints(Integer points)
    • property

      public EarningRuleLoyaltyOrderMetadata property(String property)
    • getProperty

      @Nullable public String getProperty()
      Order metadata property.
      Returns:
      property
    • setProperty

      public void setProperty(String property)
    • equals

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

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • fromJson

      public static EarningRuleLoyaltyOrderMetadata fromJson(String jsonString) throws IOException
      Create an instance of EarningRuleLoyaltyOrderMetadata given an JSON string
      Parameters:
      jsonString - JSON string
      Returns:
      An instance of EarningRuleLoyaltyOrderMetadata
      Throws:
      IOException - if the JSON string is invalid with respect to EarningRuleLoyaltyOrderMetadata
    • toJson

      public String toJson()
      Convert an instance of EarningRuleLoyaltyOrderMetadata to an JSON string
      Returns:
      JSON string