equals() and hashCode() methods added to Entry.java