Reputation: 8277
What happens to instance variables in a activity class after minimizing and maximizing the application when on that particular activity. I couldn't find a straight forward answer to this question. Also will variables that hold references to expensive resources like a DB connection be treated differently?
Upvotes: 0
Views: 110
Reputation: 43728
Don't rely on any behaviour you observe, instead be sure to implement the Activity Life Cycle correctly. Whenever the onDestroy
method is called, all instance variables will be gone.
Upvotes: 1