Re: [android-developers] Re: Lifetime of static [instance] variables

2011-05-29 Thread Mark Murphy
On Sun, May 29, 2011 at 7:44 AM, Anirban Majumdar wrote: > in an android system, what's the relevance of the "Task Manager"? There is no "task manager" in Android. There is the "recent tasks" list, brought up by a long-press on the HOME button (Android 1.x and 2.x) or a dedicated soft button (An

[android-developers] Re: Lifetime of static [instance] variables

2011-05-29 Thread Anirban Majumdar
i just recalled i wanted one last thing clarified - in an android system, what's the relevance of the "Task Manager"? i was under the impression that if i were to terminate an application there, it also meant that its related process would end. Conversely, i believed that if the process related to

[android-developers] Re: Lifetime of static [instance] variables

2011-05-29 Thread Anirban Majumdar
I am so thankful to you kostya, for such an excellent and simple explanation. Lesson learnt. Thanks again. On 29 May 2011 15:13, "Kostya Vasilyev" wrote: > Replying back to the list. > > Most (all?) platforms' model is process == application (more or less). > > In Android, there really is no such

[android-developers] Re: Lifetime of static [instance] variables

2011-05-29 Thread Kostya Vasilyev
Replying back to the list. Most (all?) platforms' model is process == application (more or less). In Android, there really is no such thing as "the application" (there is, but it is useful to ignore it at first). Therefore, one should unlearn that equality between "application" and process The u

[android-developers] Re: Lifetime of static [instance] variables

2011-05-28 Thread DanH
Static and instance variables are two different things. A static variable "lives" for the lifetime of the loaded class (which may be shorter than the lifetime of the JVM). An instance variable "lives" for the lifetime of the object (instance of the class) that contains it. I have no idea what yo

Re: [android-developers] Re: Lifetime of static [instance] variables

2011-05-28 Thread Kostya Vasilyev
Your application logic should be coded in such a way that the process can be killed at any time (usually once it's in the background), or not be killed, and still work correctly. There is no callback when the process is killed. Pressing the back key always finishes the current activity - the back

[android-developers] Re: Lifetime of static [instance] variables

2011-05-28 Thread Anirvan
thanks for the response Kostya. but i does one truly determine that the application 'process' has terminated? for testing, i've created a single Activity which serves as the Main. when i press the back button after launching this activity, the app ends. i've also verified that the app is no longer