- public String toString()
- public boolean equals(Object other)
- public int hashCode()
The x.toString() method is used by System.out.println(x) for any class type variable x.
Test for equality for basic types use the == operator.
Test for equality for class types must use the 'equals' method, not the == operator.
Several Java builtin data structure classes make use of the hashCode method.