Android Development Notes-2

Summary:SDK, ADB, Active, Intents and Tasks

-The Android SDK is made of mostly off-the-shelf components, plus some purpose-built components. In many cases, configurations, plug-ins, and extensions adapt these components to Android. The Android SDK is a study in the efficient development of a modern and complete SDK. 

-adb is a program that enables you to control both emulators and devices, and to run a shell in order to execute commands in the environment of an emulator or device. 

-The Dalvik Debug Monitor Server (DDMS) is a traffic director between the single port that Eclipse (and other Java debuggers) looks for to connect to a Java Virtual Machine
(JVM) and the several ports that exist for each Android device or virtual device, and for each instance of the Dalvik virtual machine (VM) on each device. 


-Android introduces a richer and more complex approach by supporting multiple application entry points. Android programs should expect the system to start them in different places, depending on where the user is coming from and what she wants to do next.

-An Android activity is both a unit of user interaction—typically filling the whole screen of an Android mobile device—and a unit of execution. When you make an interactive Android program, you start by subclassing the  Activity class. 

-How, then does one activity invoke another, and pass information about what the user wants to do? The unit of communication is the  Intent class. An  Intent represents an
abstract description of a function that one activity requires another activity to perform

[java]  view plain copy 在CODE上查看代码片 派生到我的代码片
  1. public class TestActivity extends Activity {  
  2. /** Called when the activity is first created. */  
  3. @Override  
  4. public void onCreate(Bundle savedInstanceState) {  
  5. super.onCreate(savedInstanceState);  
  6. setContentView(R.layout.main);  
  7. }  
  8. }  
-When the system starts this activity it calls the constructor for  TestActivity , a subclass of  Activity , and then calls its  onCreate method. This causes the view hierarchy described in the main.xml file to load and display. The  onCreate method kicks off the life cycle of the  Activity

-Each activity in an Android application is largely separate from other activities

-applications describe an Intent that they want to execute and ask the system to find one that matches



Next: Android Component

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值