I know that this.toString()
does not print the address of the object but the hash code. And I have read discussions like this one as well
But, lets say this.toString()
prints the same value on 2 occasions and a different value on the 3rd occasion. Then, can I conclude that the object on the first 2 occasions was the same and the third occasion was different?
I am trying to determine(only for testing) if an object is the same one or a different one. Like say this
points to same address or different.
Any better ways of checking if an object is the same or different one in Java running on Android devices? Or if I could get the address of the object in some way then the whole dilemma is resolved.