1. View Startup log
[2011-01-11 14:44:21-bmi] Android launch!
[2011-01-11 14:44:21-bmi] adb is running normally.
[2011-01-11 14:44:21-bmi] Performing COM.DEMO.ANDROID.BMI.BMI activity launch
[2011-01-11 14:44:21-bmi] Automatic Target mode:preferred AVD ' Android2.3 ' is available on emulator ' emulator-5554 '
[2011-01-11 14:44:21-bmi] Uploading bmi.apk onto device ' emulator-5554 '
[2011-01-11 14:44:21-bmi] Installing bmi.apk ...
During the installation process, the framework registers with Androidmanifest.xml, logs on to the activity created by the application, and implements the service that is noted to be used.
* When installing an application, the Android framework registers the information with the application's manifest
The Android framework is in the registry. "
[2011-01-11 14:44:28-bmi] success!
[2011-01-11 14:44:28-bmi] Starting activity Com.demo.android.bmi.Bmi on device emulator-5554
[2011-01-11 14:44:30-bmi] ActivityManager:Starting:Intent {act=android.intent.action.main Cat=[android.intent.category.launcher] cmp= com.demo.android.bmi/. BMI}
Start intent with Activitymanager
[2011-01-11 14:44:32-bmi] Attempting to connect debugger to ' Com.demo.android.bmi ' on port 8608
2. Interpreting the information conveyed by the manifest file
<?xml version= "1.0" encoding= "Utf-8"?>
<manifest xmlns:android= "Http://schemas.android.com/apk/res/android"
Package= "Com.demo.android.bmi"
Android:versioncode= "1"
Android:versionname= "1.0" >
<application android:icon= "@drawable/icon" android:label= "@string/app_name" >
<activity android:name= ". Bmi "
Android:label= "@string/app_name" >
<intent-filter>
<action android:name= "Android.intent.action.MAIN"/>//Description This activity is the entry for this application.
<category android:name= "Android.intent.category.LAUNCHER"/>
</intent-filter>
</activity>
</application>
<USES-SDK android:minsdkversion= "9"/>
</manifest>
Add a application to the application frame, its icon is Drawable/icon, its name is String/app_name
The application defines a major activity, and when we start the program, the virtual opportunity to find
Defines [Android.intent.category.LAUNCHER] content. Bmi]activity, and call execution.
In addition, the operating process of Android application is mainly found in four kinds of vectors:
Activity/broadcast Intent receiver/service/content Provider
3. Android Activity
Each activity is usually responsible for processing a screen's content. You can view activity as a control,activity in the MVC pattern that manages the UI and accepts event firings.
4. Android Intent
The transfer of information can be achieved through intent between activity.
5. Android Debug
The procedures and parameters that can be checked through log records are consistent with our expectations.
6. Activity cycle (LifeCycle)
On the Android platform, only one activity is active (active) or running (Running) at the same time.
Other activity is in the state of not starting (Dead), stopping (Stopped), or pausing (pause).
The above seven states can be summed up into three groups 1, resource allocation (Create/destroy) 2, Visible and Invisible (start/restart/stop) 3, whether the user directly access the screen (resume/stop)7. Android PreferencesUse Preferences to remember the last set of data and reduce duplicate input.
Learn about Android in Layman's notes