Example #1
0
 @Override
 public boolean equals(Object obj) {
   if (this == obj) return true;
   if (obj == null) return false;
   if (getClass() != obj.getClass()) return false;
   Customer other = (Customer) obj;
   if (adress == null) {
     if (other.adress != null) return false;
   } else if (!adress.equals(other.adress)) return false;
   if (email == null) {
     if (other.email != null) return false;
   } else if (!email.equals(other.email)) return false;
   if (name == null) {
     if (other.name != null) return false;
   } else if (!name.equals(other.name)) return false;
   if (type != other.type) return false;
   return true;
 }