package model;

public class Type {
	Integer id;
	String name;
	Integer rate;
	
	public static Type other = new Type(-1,"other");
	
	public Type(Integer id, String name){
		this.id = id;
		this.name = name;
	}
	
	public Type(Integer id, String name, Integer rate){
		this.id = id;
		this.name = name;
		this.rate = rate;
	}
	
	public Type(){
		
	}
	
	public Integer getId() {
		return id;
	}
	public void setId(Integer id) {
		this.id = id;
	}
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public Integer getRate() {
		return rate;
	}
	public void setRate(Integer rate) {
		this.rate = rate;
	}
}

@@ -77,17 +77,16 @@
  rate;%0D%0A
-%09
 %0D%0A%09publi
@@ -119,16 +119,17 @@
 Type(-1,
+ 
 %22other%22)
@@ -131,17 +131,16 @@
 her%22);%0D%0A
-%09
 %0D%0A%09publi
@@ -170,16 +170,17 @@
 ng name)
+ 
 %7B%0D%0A%09%09thi
@@ -208,33 +208,32 @@
 me = name;%0D%0A%09%7D%0D%0A
-%09
 %0D%0A%09public Type(I
@@ -269,16 +269,17 @@
 er rate)
+ 
 %7B%0D%0A%09%09thi
@@ -332,25 +332,24 @@
  rate;%0D%0A%09%7D%0D%0A
-%09
 %0D%0A%09public Ty
@@ -356,20 +356,18 @@
 pe()
+ 
 %7B%0D%0A
-%09%09
 %0D%0A%09%7D%0D%0A
-%09
 %0D%0A%09p
@@ -401,32 +401,34 @@
 return id;%0D%0A%09%7D%0D%0A
+%0D%0A
 %09public void set
@@ -462,24 +462,26 @@
  = id;%0D%0A%09%7D%0D%0A
+%0D%0A
 %09public Stri
@@ -508,32 +508,34 @@
 turn name;%0D%0A%09%7D%0D%0A
+%0D%0A
 %09public void set
@@ -572,32 +572,34 @@
 me = name;%0D%0A%09%7D%0D%0A
+%0D%0A
 %09public Integer 
@@ -631,16 +631,18 @@
 e;%0D%0A%09%7D%0D%0A
+%0D%0A
 %09public 
@@ -696,11 +696,227 @@
 e;%0D%0A%09%7D%0D%0A
+%09%0D%0A%09@Override%0D%0A%09public int hashCode() %7B%0D%0A%09%09return this.id;%0D%0A%09%7D%0D%0A%0D%0A%09@Override%0D%0A%09public boolean equals(Object obj) %7B%0D%0A%09%09if (!(obj instanceof Type)) %7B%0D%0A%09%09%09return false;%0D%0A%09%09%7D%0D%0A%0D%0A%09%09return ((Type) obj).id == this.id;%0D%0A%09%7D%0D%0A
 %7D%0D%0A

add hashCode so contains key would work