@Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (!(o instanceof MyComparator)) return false;

        MyComparator myComparator = (MyComparator) o;

        if (age != myComparator.age) return false;
        if (name != null ? !name.equals(myComparator.name) : myComparator.name != null) return false;

        return true;
    }