On Apr 9, 8:11 am, Mark Murphy <[email protected]> wrote:
> Donal Rafferty wrote:
> > The singleton wont be killed by the system automatically like a service
> > which could lead to GC problems
>
> Correct. Objects held in static data members, or referenced from a
> static data member, will not be garbage collected. Hence, you need to
> remember to null out those static data member references. Services, on
> the other hand, will garbage collect automatically, assuming you do not
> put one in a static data member yourself.
>
Why it should be garbage collected? It lives and dies with
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

To unsubscribe, reply using "remove me" as the subject.

Reply via email to