Android四大组件介绍.ppt
Android Fantastic Four
Jacky Cai – 2017/07/07
Fantastic Four
1
Activity
2
Service
3
Content Provider
4
Broadcast Receiver
5
目录
Contents
Fantastic Four
The Design Pattern Behind
Model represents an object carrying data. It can also have logic to update controller if its data changes.
View represents the visualization of the data that model contains.
Controller interacts with model and view, controls data flow, updates view when data changes. It keeps view and model separate.
Various Resources
To Do List
#FF0000FF
5px
Resource - Layout
Android supports variety of resources from simple values such as strings and colors to complex resources like layout, images and themes.
Resource - Misc
Fantastic Four
1
Activity
2
Service
3
Content Provider
4
Broadcast Receiver
5
目录
Contents
Activity - Life Cycle
Activity - Task
Task is a collection of activities that users interact with when performing a certain job. The activities are arranged in a stack(back stack) in the order in which each activity is opened. For example. If the user presses the Back button, that new activity is finished and popped off the stack.
Activity - Hands on
Ho