The following is the first few sections of a chapter from The Busy Coder's Guide to Android Development, plus headings for the remaining major sections, to give you an idea about the content of the chapter.
CPU issues tend to manifest themselves in three ways:
Regardless of how the issue appears to the user, in the end, it is a
matter of you using too much CPU time. That could be simply because
your application is written to be constantly active (e.g., you have
an everlasting service that uses
TimerTask to wake up every second
and do something). There is little anyone can do to help that short
of totally rethinking the app’s architecture (e.g., switch to
AlarmManager and allow the user to configure the polling period).
However, in many cases, the problem is that you are using algorithms – yours or ones built into Android — that simply take too long when used improperly. This chapter will help you identify these bottlenecks, so you know what portions of your code need to be optimized in general or apply the techniques described in later chapters of this part of the book.
Understanding this chapter requires that you have read the core chapters and understand how Android apps are set up and operate. Reading the introductory chapter to this trail is also a good idea.
The preview of this section is out seeking fame and fortune as the Dread Pirate Roberts.
The preview of this section was lost due to a rupture in the space-time continuum.
The preview of this section is unavailable right now, but if you leave your name and number at the sound of the tone, it might get back to you (BEEEEEEEEEEEEP!).
The preview of this section was abducted by space aliens.