modified serialization code, added equals/hashcode to Contact