String, Date, File, wrapper classes, etc. all rewrite the equals() method in the Object class. After rewriting, it is not about whether the two referenced addresses are the same, but about whether the "entity content" of the two objects is the same.
String, Date, File, wrapper classes, etc. all rewrite the toString() method in the Object class. Make the "entity content" information be returned when the object's toString() is called