Learn about android 1 (learn about android) and learn about android

Source: Internet
Author: User

Learn about android 1 (learn about android) and learn about android

Disclaimer: All content in the android learning file is sorted fromThe first line of code Android will not be repeated in the following article. Want to see the original can buy books to see, or go to the author's blog http://blog.csdn.net/guolin_blog? Viewmode = contents. It's a bit of water to write.


1. android system architecture

1. At the Linux kernel layer, the android system is based on the linux2.6 kernel.

2. System Runtime Library layer, which provides main features for the android system through some c/c ++ Libraries

3. Application Framework layer, which provides various APIs that may be used to build applications

4. Application Layer. All applications installed on mobile phones belong to this layer.

2. Four components of android: Activity, Service, BroadcastReceive broadcast receiver, and ContentProvider.

3. Create a helloworld android Application

Directory analysis:

Src: place all of our java code

Gen: This directory is automatically generated. There is mainly an R. java file. Any resource added to your project will generate a corresponding resource id. This file should never be modified manually.

Assets: stores files packaged with the program. When your program runs, you can dynamically read the content of these files. In addition, if your program uses the WebView function to load local webpages, all webpage-related files are stored in this directory.

Bin: It mainly contains some files automatically generated during compilation.

Libs: If your project uses third-party jar packages, you need to put these jar packages under the libs directory, the jar packages under this directory are automatically added to the build path.

Res: all the images, la S, strings, and other resources used are placed under this directory.

AndroidMainfest. xml: This is the configuration file of the android project. All the four components defined in the program must be registered in this file. In addition, you can add a permission statement to the application in this file, or rewrite the minimum compatible version and target version of the specified program during creation.

Project. properties: Specifies the SDK version used for compiling a program with a line of code.

4. Use the Log tool Log of Android

Log. v () is used to print the most trivial and least meaningful logs. Verbose is the lowest level in android logs.

Log. d () prints some debugging information, which helps debug Programs and analyze problems.

Log. I () is used to print some important data that you really want to see and can help you analyze user behavior. The corresponding level is info.

Log. w () prints the warning information, prompting that the program may have potential risks in this place. It is recommended to fix the issue. The corresponding level is war.

Log. e () is used to print the error information in the program. This generally indicates that your program has a serious problem and must be repaired as soon as possible. The corresponding level is error.

The log details are described in later articles.



























































I want to learn about Android development after work, but I don't know where to start learning Android?

Android development is divided into application development and underlying development. application development is relatively less difficult. You need to master the java language, and the underlying layer needs to learn the C language and drive it. We recommend that you go to the qianfeng Internet to learn, comprehensive information and system comparison!

I want to learn about android recently. Can I buy an android mobile phone?

If you are not using a smartphone, I can only say that you need to buy an android device. You have never used smart machines. You may not know any of these functions.
If you are using ipone, there is no need for it. You can perform the android demo Based on the iPhone interface. This is also the sorrow of android. android programmers are all converted into iPhones ....
It is generally like an android program. What you write is beautiful and easy to use first. Finally, it must be installed on your android phone to tune bugs. In the early stage, there is not much need, because you are just an entry, and there will be a virtual machine installed on android in eclipse, but it will be relatively slow, but there is no problem if you do a small demo.
After your demo is mature, you need to transplant it to the android phone. You need to consider using an android phone, because you cannot install the iPhone.
Any applicable version can be used. The most widely used version is android2.3.3, but now the number of mobile phones reaches 4.0 or above. You can choose a price-performance ratio.

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.