That description is pretty misleading. It doesn't give you complete control over management of application lifecycle, and I really have no idea what it means in the second bullet point (you could just as well do what I think it is describing using a static global).
On Wed, Mar 9, 2011 at 6:31 AM, DebUggEr <[email protected]> wrote: > Seems like heres the answer. I am not an expert but do consider and let me > know too. > > ANDROID.APP.APPLICATION CLASS > > Each Android application can have at most one > android.app.Applicationassociated > with it. You are responsible for sub-classing the Application Class, and > it is used to maintain a global state of the application across all > Activites. Conceptually, you can think of it as a non-static singleton its > life cycle being managed by Android OS. > *Benefits:* > > - Gives you complete control over the management of application > life-cycle, so resources can be properly initialised and disposed of. > - Provides a single entry point where *any* Activity or Service within > the application can gain access to the desired object > > *Drawbacks:* > > - Can only expose information to Activities and Services within the > application > > -- > You received this message because you are subscribed to the Google > Groups "Android Developers" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group at > http://groups.google.com/group/android-developers?hl=en > -- Dianne Hackborn Android framework engineer [email protected] 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 [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

