adds equals, toString, and hashCode