package ru.job4j.map;

import java.util.Calendar;

public class User {

    private String name;
    private int children;
    private Calendar birthday;

    public User(String name, int children, Calendar birthday) {
        this.name = name;
        this.children = children;
        this.birthday = birthday;
    }


    @Override
    public int hashCode() {
        int result = name != null ? name.hashCode() : 0;
        result = 31 * result + children;
        result = 31 * result + (birthday != null ? birthday.hashCode() : 0);
        return result;
    }
}

@@ -313,17 +313,16 @@
 %0A    %7D%0A%0A
-%0A
     @Ove
@@ -342,90 +342,147 @@
 lic 
-int hashCode() %7B%0A        int result = name != null ? name.hashCode() : 0
+boolean equals(Object o) %7B%0A        if (this == o) return true;%0A        if (o == null %7C%7C getClass() != o.getClass()) return false
 ;%0A
+%0A
         
 resu
@@ -481,145 +481,264 @@
     
-result = 31 * result + children;%0A        result = 31 * result + (birthday != null ? birthday.hashCode() : 0);%0A        return result
+User user = (User) o;%0A%0A        if (children != user.children) return false;%0A        if (name != null ? !name.equals(user.name) : user.name != null) return false;%0A        return birthday != null ? birthday.equals(user.birthday) : user.birthday == null
 ;%0A    %7D%0A
 %7D%0A
@@ -735,10 +735,11 @@
 ;%0A    %7D%0A
+%0A
 %7D%0A

task 1004