View Javadoc
1   package org.oxerr.viagogo.model.request.inventory;
2   
3   import java.io.Serializable;
4   
5   import org.apache.commons.lang3.builder.EqualsBuilder;
6   import org.apache.commons.lang3.builder.HashCodeBuilder;
7   
8   public class CountryRequest implements Serializable {
9   
10  	private static final long serialVersionUID = 2023021301L;
11  
12  	/**
13  	 * The two-letter ISO 3166 code for the country.
14  	 */
15  	private String code;
16  
17  	public CountryRequest() {
18  	}
19  
20  	public CountryRequest(String code) {
21  		this.code = code;
22  	}
23  
24  	public String getCode() {
25  		return code;
26  	}
27  
28  	public void setCode(String code) {
29  		this.code = code;
30  	}
31  
32  	@Override
33  	public int hashCode() {
34  		return HashCodeBuilder.reflectionHashCode(this);
35  	}
36  
37  	@Override
38  	public boolean equals(Object obj) {
39  		if (obj == null) {
40  			return false;
41  		}
42  		if (obj == this) {
43  			return true;
44  		}
45  		if (obj.getClass() != getClass()) {
46  			return false;
47  		}
48  		CountryRequest rhs = (CountryRequest) obj;
49  		return EqualsBuilder.reflectionEquals(this, rhs);
50  	}
51  
52  }