Пример #1
0
 @Override
 public boolean equals(Object obj) {
   if (obj instanceof User) {
     User that = (User) obj;
     return Objects.equal(email, that.email);
   }
   return false;
 }
Пример #2
0
 @Override
 public int hashCode() {
   return Objects.hashCode(email);
 }