Package com.adyen.model.management
Class OrderItem
- java.lang.Object
-
- com.adyen.model.management.OrderItem
-
public class OrderItem extends Object
OrderItem
-
-
Field Summary
Fields Modifier and Type Field Description static StringJSON_PROPERTY_IDstatic StringJSON_PROPERTY_INSTALLMENTSstatic StringJSON_PROPERTY_NAMEstatic StringJSON_PROPERTY_QUANTITY
-
Constructor Summary
Constructors Constructor Description OrderItem()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)Return true if this OrderItem object is equal to o.static OrderItemfromJson(String jsonString)Create an instance of OrderItem given an JSON stringStringgetId()The unique identifier of the product.LonggetInstallments()The number of installments for the specified product `id`.StringgetName()The name of the product.IntegergetQuantity()The number of items with the specified product `id` included in the order.inthashCode()OrderItemid(String id)OrderIteminstallments(Long installments)OrderItemname(String name)OrderItemquantity(Integer quantity)voidsetId(String id)The unique identifier of the product.voidsetInstallments(Long installments)The number of installments for the specified product `id`.voidsetName(String name)The name of the product.voidsetQuantity(Integer quantity)The number of items with the specified product `id` included in the order.StringtoJson()Convert an instance of OrderItem to an JSON stringStringtoString()
-
-
-
Field Detail
-
JSON_PROPERTY_ID
public static final String JSON_PROPERTY_ID
- See Also:
- Constant Field Values
-
JSON_PROPERTY_INSTALLMENTS
public static final String JSON_PROPERTY_INSTALLMENTS
- See Also:
- Constant Field Values
-
JSON_PROPERTY_NAME
public static final String JSON_PROPERTY_NAME
- See Also:
- Constant Field Values
-
JSON_PROPERTY_QUANTITY
public static final String JSON_PROPERTY_QUANTITY
- See Also:
- Constant Field Values
-
-
Method Detail
-
getId
public String getId()
The unique identifier of the product.- Returns:
- id
-
setId
public void setId(String id)
The unique identifier of the product.- Parameters:
id-
-
getInstallments
public Long getInstallments()
The number of installments for the specified product `id`.- Returns:
- installments
-
setInstallments
public void setInstallments(Long installments)
The number of installments for the specified product `id`.- Parameters:
installments-
-
getName
public String getName()
The name of the product.- Returns:
- name
-
setName
public void setName(String name)
The name of the product.- Parameters:
name-
-
getQuantity
public Integer getQuantity()
The number of items with the specified product `id` included in the order.- Returns:
- quantity
-
setQuantity
public void setQuantity(Integer quantity)
The number of items with the specified product `id` included in the order.- Parameters:
quantity-
-
equals
public boolean equals(Object o)
Return true if this OrderItem object is equal to o.
-
fromJson
public static OrderItem fromJson(String jsonString) throws com.fasterxml.jackson.core.JsonProcessingException
Create an instance of OrderItem given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of OrderItem
- Throws:
com.fasterxml.jackson.core.JsonProcessingException- if the JSON string is invalid with respect to OrderItem
-
toJson
public String toJson() throws com.fasterxml.jackson.core.JsonProcessingException
Convert an instance of OrderItem to an JSON string- Returns:
- JSON string
- Throws:
com.fasterxml.jackson.core.JsonProcessingException
-
-