Android Community Forums - View Single Post - Official Thread: T-Mobile G1 Q&A - Your Questions Answered
View Single Post
  #104  
Old 10-10-2008, 04:43 PM
pcaustin pcaustin is offline
pcaustin has no status.
Smoke signaler
 
Join Date: Oct 2008
Posts: 6
pcaustin is on a distinguished road
Default re: Official Thread: T-Mobile G1 Q&A - Your Questions Answered

I may not be qualified to describe the multi-tasking but I haven't seen a concise description yet so I'll give it a try:

All Applications so far are in Java and conform to a very specific interface. They are divided into UI pieces and Services. The UI piece for sure, and I think even the services have the ability to save and restore it's state. This gives the OS the ability to shut down and restore an application when necessary. If I understand right, the UI is likely to get shut down anytime you're not actually using it, but services will continue to run unless resources are critically low.

In addition, services register their interest in responding to a stimulus (an "Intent") and it seems like they could easily be hibernated until needed. Hmm, come to think of it, this sounds like "event driven programming" taken to the a level where the process can actually be unloaded between events.

So, for example, I don't know anything about the actual IM applications, but I can guess how this might be applied. Anything having to do with composing an AIM message or displaying your buddy-list will probably be "hibernated" when you're not using it, but the service can still respond to incoming messages or continue to try to send messages even after you've switched away from the UI.
Reply With Quote