Statics are statics -- they are global to the process. So their value will last for the lifetime of the process, which is usually much longer than an individual activity instance.
On Tue, Jul 14, 2009 at 12:52 PM, Richard Schilling < richard.rootwirel...@gmail.com> wrote: > > I just ran into a situation where it looks like a static variable > reference is persisted across activity sessions. I didn't expect that > because I thought that when an activity exits, it's de-referenced and > garbage collected. > > I am wondering if anyone can shed some (more) light on when the VM > eliminates object references for Activities and Services and in > particular when static variables get reset to default values? > > > Thanks. > > Richard Schilling > Root Wireless > > > > -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---