1.andro system architecture: Linux kernel Layer ( provides driver ), System Runtime Library layer and Android Runtime Library ( provides the main features of A/C + + library, such as Sqlite,opengl,webkit and Dalvik virtual machines ), apply the framework layer, the application layer.
2.android Four components: activities (everything the activity interface can see ), Services (service background runs even if the user exits the app will continue to run), broadcast receivers (Broadcastreceiver can receive foreign broadcast messages) and content providers (provider makes it possible to share data between programs and programs).
3. Project directory File Description:
Src:java code Interface layout file Androidmanifest
Libs: Third-party resource bundles
Values: This folder represents the storage string
Menu: This folder represents the menus file
Drawable: Represents a picture file
Layout: representing the layouts file
4. Program running Process:
Androidmanifest.xml (record activity's main run, equivalent to main)
|
Run the corresponding Java class (inheriting to activity or actionbaractivity) according to the file above
|
Load the corresponding interface resource file (Setcontentview (R.layout.testhello)in the OnCreate method according to the Java class above;
|
Load resource information for a specific values folder based on the contents of the layout file
5. In the XML front-end file and Java back-end code, call the resource format in the Values folder:
R.string.hello_word (Java code gets the string)
@String/hello_word (Get the string in the XML layout file)
The above 2 methods can be followed and so on, such as Id,menu,style and so on
The definition ID method is:android:id= "@+id/button1"
6. Master Log, it provides 5 methods of recording, you can use a custom key and other methods to log information and select a level to filter certain data,
Importing namespaces: ImportAndroid.util.Log;
LOG.V () log.d () log.i () LOG.W () LOG.E ()
Android Beginner to proficiency (i)