I need to distinguish my app's installations so I generate a UUID in my app via java.util.UUID.randomUUID()
then save it as a String
in the shared preferences. However, when I go to the phone's Settings, manage the applications, click on my app, and press "Clear Data," the next time my app runs, a new UUID is generated. I believe this is because the previous shared prefs has been deleted.
Is there a way for me to create a UUID that persists for as long as the app is installed, even when "Clear Data" is pressed from the Settings?