10 kinds of techniques can improve Android application performance

Reprinted from:

With the development of mobile phone platform and provides application promotion, quality has become one of the most important factors of success. If the application is unable to provide the powerful and stable user experience, it will soon be users to uninstall. Developers need to remember is, although the Android intelligent mobile phone and tablet computer speed increasing, but its application is still running in a resource constrained environment, the battery and the processor performance and new desktop computer, notebook computer still has a gap. The following is some application of the optimal operation effect:
Let's start with some coding tips for responsive applications.

Tip 1: from the beginning of good programming

The design style has been accepted by the user operation rules and standards, these long-standing coding rules are equally applicable to the Android application, especially if they use internal equipment services.
For example, suppose you write the application needs to geographic location based services. Only need to register a location update when necessary, without the need to update the information, to ensure the application of the update process. This would help to save processor power and system equipment burden.

Tip 2: keep the flexibility of application
To maintain the flexibility of application by using AsyncTask, IntentService or a custom background service. Use loaders to simplify the management of long loading data, such as the cursor. Don't let the application in other process is slow or completely still.
If an operation takes time and resources, this process should be separate asynchronous processing, so that your application can keep running smoothly. You can use this method of operation includes: disk read and write access, content provider, database and network, other tasks take longer.

Tip 3: use the new Android SDK version and API
Maintain the application update, using the latest Android platform provides. With the development of Android platform, it is improved. Some of the features have been removed, or replaced with better options. The core of vulnerability in API has been fixed, the API performance has been improved. The platform has been the introduction of new API loader and the like, to help developers write is more stable and sensitive reaction.
The application of Android 3 supports hardware acceleration, you can apply. It is submitted with the understanding, the performance of the best change over time. The new content and API wise developers will update platform released.

Tip 4: check Strict Mode
You can use the "StrictMode" Android API to find programming problems. StrictMode will help you to identify whether the application is memory consuming, can also help you to check whether the application is trying to carry out the modular operation long.
Class StrictMode (Note: android.os.StrictMode) release and Android 2.3 over the same period.

Tip 5: disable before release or minimize debugging and diagnosis
You may be certain debugging code built in Android application development. In the application before release to ensure that these functions are minimized or completely disable.
Next, let's discuss how to use user interface design principles for good to make your application faster loading.

Tip 6: keep the layout simple natural
Concise and Natural layout will load faster. Don't let too much unnecessary content screen layout. Spend the time to develop simple user interface the user can effectively use, not to cram too much functionality onto a single screen. Not only will this help application performance, and it will help the user applications use more effectively.
Segmentation can help compartmentalize user interface functionality, without sacrificing the applications in a variety of different equipment flexibility.

Tip 7: according to the destination device to adjust the application resource
To adjust the resources according to the specific device configuration, so that they can effectively loading. In the image resources, this is particularly important. If there is a large picture of resources need to load your application, then to make adjustments.
Another technique is to, when to many kinds of equipment for the target, maintain the application package file size, only in which contained the core resources of the operation can be used, and then let the user according to the specific equipment application download other content.

Tip 8: use Hierarchy Viewer tools
The Hierarchy Viewer tool can help to relieve you from your application layout of the loopholes in the. It also provides a lot of valuable information, such as each View control requires the long time. Find the problem areas, solve the problem in this way will be more simple.

Tip 9: use the layoutopt tool
The layoutopt tool is a simple command-line tool can help you identify control matters, unnecessary and other ways to collapse your layout resources, enhance the performance of. It can help you find the redundant layout control unnecessary. Fewer and shallower layouts application performance.
Finally, think in the application to achieve the best condition, the test.

Tip 10: use Traceview and other Android application compression tools
There are many compression can be used tools in Android SDK. Perhaps the most popular tool is Traceview, a graphical tool that can help you debug and find performance problems in its application.

There are many ways to speed up the performance of your Android application. Some involve using specific algorithms, others rely on some true debugging and performance monitoring technology. The Android platform has many kind of free tools can be used to help track and adjust the performance problems in the application of. You already know the above 10 kinds of skills, you can now try to use them!

Started by Marico at February 11, 2016 - 7:28 PM

I'm fine, thanks

Posted by Gabriel at February 12, 2016 - 7:58 PM

Very good, thanks for sharing

Posted by Opie at February 26, 2016 - 8:07 PM

The reply to 2012-03-27 17:45:53 was a moderator to delete

Posted by Webb at March 10, 2016 - 8:49 PM

Preemption,,, and have time to look at

Posted by Mercedes at March 19, 2016 - 9:37 PM

Thank you for sharing

Posted by Esther at March 23, 2016 - 10:17 PM

Thank you, well worth a look

Posted by Gwendolyn at April 04, 2016 - 10:57 PM

Just started learning Android, is used as a standard of learning.. Thank you for. . . .

Posted by Benedict at April 14, 2016 - 10:59 PM

The reply to 2012-03-27 21:46:16 was a moderator to delete

Posted by Stacy at April 19, 2016 - 11:14 PM

The reply to 2012-03-28 10:30:22 was a moderator to delete

Posted by Boris at May 04, 2016 - 11:24 PM

The reply to 2012-03-28 10:30:23 was a moderator to delete

Posted by Rod at May 19, 2016 - 12:20 AM

Well, thank you. Read

Posted by Chapman at May 27, 2016 - 12:31 AM

Cool! Very helpful

Posted by Quennel at June 07, 2016 - 12:32 AM

Thank you so gas

Posted by Joy at June 16, 2016 - 1:24 AM

Thank you for sharing···

Posted by Leonard at June 26, 2016 - 2:22 AM

Thank you for sharing~~

Posted by Donahue at July 01, 2016 - 2:42 AM

Very good, thanks for sharing

Posted by Zero at July 04, 2016 - 3:05 AM

Learning, very good!

Posted by Barton at July 17, 2016 - 3:10 AM

The reply to 2012-03-28 10:05:16 was a moderator to delete

Posted by Owen at July 25, 2016 - 3:46 AM

Good, good learning, good ah

Posted by Cher at August 06, 2016 - 3:52 AM

During the past,

Posted by Saxon at August 12, 2016 - 3:53 AM

Very good, very powerful

Posted by Boyce at August 24, 2016 - 4:02 AM

I'm fine, thanks

Posted by Katherleen at September 03, 2016 - 4:24 AM

The reply to 2012-03-28 08:59:29 was a moderator to delete

Posted by Dolores at September 06, 2016 - 5:22 AM

The above are all in good

Posted by Dennis at September 15, 2016 - 5:31 AM

In the period to see the video introduction, this have a look

Posted by Yves at September 17, 2016 - 6:02 AM

The reply to 2012-03-28 08:59:30 was a moderator to delete

Posted by Adalheid at September 19, 2016 - 6:39 AM

The layman can not learn? !

Posted by Virgil at December 02, 2016 - 2:58 PM

Thank you, well worth a look

Posted by Ted at December 12, 2016 - 3:56 PM

Good learning.

Posted by Ignativs at December 25, 2016 - 4:37 PM

But with the new SDK, many users of the mobile phone are not on

Posted by Solomon at January 09, 2017 - 4:58 PM

The reply to 2012-04-05 13:44:53 was a moderator to delete

Posted by Abby at January 09, 2017 - 6:07 PM

Very good, thanks for sharing.

Posted by Zoe at January 11, 2017 - 7:15 PM

Then I try, thank you!

Posted by Omar at January 12, 2017 - 6:47 PM

Study, thanks

Posted by Matilda at January 13, 2017 - 5:44 PM