Timeline for Do we always need to override equals/hashcode when creating a new class?
Current License: CC BY-SA 4.0
3 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Oct 3, 2019 at 20:18 | comment | added | Sisir | Not all classes are POJOs. For example take the case of View or Controller classes in MVC, classes doing complex arithmetic computations, classes providing abstraction to more low-level functionalities. This list can go on and on. And in majority of these cases you dont need the equality method | |
Oct 3, 2019 at 20:11 | comment | added | Jim | Could you elaborate a bit on the need for objects that are not POJOs? | |
Oct 3, 2019 at 20:06 | history | answered | Sisir | CC BY-SA 4.0 |