Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Java equals()

Name: Anonymous 2009-05-18 5:38

I want to put an equals() method in all of mine immutable (final) classes.
Should I use the instanceof or the getClass() approach?

thanks!

Name: Anonymous 2009-05-19 5:54

>>27
This might surprise you but javas "primitive" integers exhibit intelligent autoboxing behaviour, in fact. A primitive integer could even be considered a wrapper around its Integer object that simply hides all the details until neccesary- what better effeciency could you ask for? On the subject of effeciency, java arithmetic is actually benchmarkedly faster than Se and Sepples arithmetic, a testament to the sound design decisions of the Sun Java team.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List