Is it possible to retrieve the Intent which came in onNewIntent on a later timing?
For example, lets assume that I have a LiveData Observer in my Activity or Fragment, and when onChange is called I want to check if there was a new Intent earlier, with some content in it which is different then the original Intent that launched the Activity?
I don't want to keep a class member variable which holds the new Intent..
Does such thing possible?
You do not have much of a choice.
Only if you override
onNewIntent()and store theIntentthat you get somewhere.For this, you could override
onNewIntent(), compare the content with that from the originalIntent(getIntent()), store the results of that comparison in a class field, and then reference that class field inonChange.