Preparations before Android project development (2): android Project Development

Source: Internet
Author: User

Preparations before Android project development (2): android Project Development

Integrate Android into my life!

In the previous article, I introduced some preparations before development. Because the length is too long and it is hard for everyone to watch, all my blogs will not be too long in the future. If it is too long, I will introduce it in several stages. Okay, no need to talk about it. Continue with the previous article!

1: All network requests must be processed by one method. The callback interface is used to process the returned data. The network status is determined before the request. If there is no network, the system returns the data directly.

This greatly reduces the power consumption of applications. By the way, the most frequently consumed applications are network connections, GPS, and various sensors. You can check these sensors to improve our efficiency.

APP performance!


2: some important global variables should be stored in their own applications. When the Application returns, the attributes of the Constants constant class may be recycled. If the access continues, the obtained value may be null, And the variables will not be recycled even if the Application returns!

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.