Yes, Integer objects are immutable.
Since you haven't overridden
equals() from java.lang.Object, you get the default implementation, which means you get this behaviour (quoted from the API):
The equals method for class Object implements the most discriminating possible equivalence relation on objects; that is, for any reference values x and y, this method returns true if and only if x and y refer to the same object (x==y has the value true).
This is why == and .equals() are (currently) the same. You need to add an equals method specific to this object...
(or similar, this is just an example
)
Dave