re-implemented equals and hashcode using apache commons library