Package com.adyen.model.transfers
Class Lodging
- java.lang.Object
-
- com.adyen.model.transfers.Lodging
-
public class Lodging extends Object
Lodging
-
-
Field Summary
Fields Modifier and Type Field Description static StringJSON_PROPERTY_CHECK_IN_DATEstatic StringJSON_PROPERTY_NUMBER_OF_NIGHTS
-
Constructor Summary
Constructors Constructor Description Lodging()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description LodgingcheckInDate(String checkInDate)The check-in date.booleanequals(Object o)Return true if this Lodging object is equal to o.static LodgingfromJson(String jsonString)Create an instance of Lodging given an JSON stringStringgetCheckInDate()The check-in date.Map<String,Object>getExplicitNulls()Returns a map of properties to be merged into the JSON payload as explicit null values.IntegergetNumberOfNights()The total number of nights the room is booked for.inthashCode()LodgingincludeNullValues(boolean includeNullValues)Configures whether null values are explicitly serialized in the JSON payload.booleanisIncludeNullValues()Returns whether null values are explicitly serialized in the JSON payload.LodgingnumberOfNights(Integer numberOfNights)The total number of nights the room is booked for.voidsetCheckInDate(String checkInDate)The check-in date.voidsetIncludeNullValues(boolean includeNullValues)Sets whether null values should be explicitly serialized in the JSON payload.voidsetNumberOfNights(Integer numberOfNights)The total number of nights the room is booked for.StringtoJson()Convert an instance of Lodging to an JSON stringStringtoString()
-
-
-
Field Detail
-
JSON_PROPERTY_CHECK_IN_DATE
public static final String JSON_PROPERTY_CHECK_IN_DATE
- See Also:
- Constant Field Values
-
JSON_PROPERTY_NUMBER_OF_NIGHTS
public static final String JSON_PROPERTY_NUMBER_OF_NIGHTS
- See Also:
- Constant Field Values
-
-
Method Detail
-
checkInDate
public Lodging checkInDate(String checkInDate)
The check-in date.- Parameters:
checkInDate- The check-in date.- Returns:
- the current
Lodginginstance, allowing for method chaining
-
getCheckInDate
public String getCheckInDate()
The check-in date.- Returns:
- checkInDate The check-in date.
-
setCheckInDate
public void setCheckInDate(String checkInDate)
The check-in date.- Parameters:
checkInDate- The check-in date.
-
numberOfNights
public Lodging numberOfNights(Integer numberOfNights)
The total number of nights the room is booked for.- Parameters:
numberOfNights- The total number of nights the room is booked for.- Returns:
- the current
Lodginginstance, allowing for method chaining
-
getNumberOfNights
public Integer getNumberOfNights()
The total number of nights the room is booked for.- Returns:
- numberOfNights The total number of nights the room is booked for.
-
setNumberOfNights
public void setNumberOfNights(Integer numberOfNights)
The total number of nights the room is booked for.- Parameters:
numberOfNights- The total number of nights the room is booked for.
-
includeNullValues
public Lodging includeNullValues(boolean includeNullValues)
Configures whether null values are explicitly serialized in the JSON payload. Default is false.
-
isIncludeNullValues
public boolean isIncludeNullValues()
Returns whether null values are explicitly serialized in the JSON payload.
-
setIncludeNullValues
public void setIncludeNullValues(boolean includeNullValues)
Sets whether null values should be explicitly serialized in the JSON payload. Default is false.
-
equals
public boolean equals(Object o)
Return true if this Lodging object is equal to o.
-
getExplicitNulls
public Map<String,Object> getExplicitNulls()
Returns a map of properties to be merged into the JSON payload as explicit null values.
-
fromJson
public static Lodging fromJson(String jsonString) throws com.fasterxml.jackson.core.JsonProcessingException
Create an instance of Lodging given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of Lodging
- Throws:
com.fasterxml.jackson.core.JsonProcessingException- if the JSON string is invalid with respect to Lodging
-
toJson
public String toJson() throws com.fasterxml.jackson.core.JsonProcessingException
Convert an instance of Lodging to an JSON string- Returns:
- JSON string
- Throws:
com.fasterxml.jackson.core.JsonProcessingException
-
-