Reputation: 495
When i convert bitmap to string with toString()
i get something like that: android.graphics.Bitmap@40da7c08. I want that name to be always the same so i can compare it. Is there any way to do it?
Upvotes: 0
Views: 142
Reputation: 2371
It would be better to extend the bitmap class and add another method to generate a unique identifier that you understand.
Upvotes: 1
Reputation: 5554
This is the default implementation of the toString()
method in Java
. Its basically the fully classified name of the class, followed by the hexcode
of the object.
I would suggest that you do your comparison based on the equals()
method or wrap your Bitmap
objects inside a class of yours and add a name or id property.
Upvotes: 0