摘要: 大家好, 今天给大家介绍下我们在应用开发中最熟悉而陌生的朋友-----Context类 ,说它熟悉,是应为我们在开发中时刻的在与它打交道,例如:Service、BroadcastReceiver、Activity等都会利用到Context的相关方法 ; 说它陌生,完全是因为我们真正的不懂Context的原理、类结构关系。Context,中文直译为“上下文”,SDK中对其说明如下:Interface to global information about an application environment. This is an abstract class whose implement.. 阅读全文
posted @ 2012-11-29 22:44 1小松 阅读(176) 评论(0) 推荐(0) 编辑
摘要: 大家好, 今天给大家介绍下我们在应用开发中最熟悉而陌生的朋友-----Context类 ,说它熟悉,是应为我们在开发中时刻的在与它打交道,例如:Service、BroadcastReceiver、Activity等都会利用到Context的相关方法 ; 说它陌生,完全是因为我们真正的不懂Context的原理、类结构关系。Context,中文直译为“上下文”,SDK中对其说明如下:Interface to global information about an application environment. This is an abstract class whose implement.. 阅读全文
posted @ 2012-11-29 22:29 1小松 阅读(287) 评论(0) 推荐(0) 编辑
摘要: MVC:MVC简介MVC是三个单词的缩写,分别为:模型(Model),视图(View)和控制Controller)在javaEE中对应关系为:Model模型---------------业务逻辑(eg:javaBean、EJB)app中的二进制的数据View视图---------------与用户交互(实现:jsp)用户界面,Android中通常将其保存在xml中Controller控制------------桥梁使用MVC是为了将M与V的代码分离,从而使同一个程序可以使用不同的表现形式。C存在的目的:确保M与V同步。Android中MVC对应关系M:app中的二进制的数据V:用户界面,And 阅读全文
posted @ 2012-11-29 21:24 1小松 阅读(225) 评论(0) 推荐(0) 编辑
摘要: 第一类:属性值为true或falseandroid:layout_centerHrizontal 水平居中android:layout_centerVertical垂直居中android:layout_centerInparent相对于父元素完全居中android:layout_alignParentBottom贴紧父元素的下边缘android:layout_alignParentLeft 贴紧父元素的左边缘android:layout_alignParentRight贴紧父元素的右边缘android:layout_alignParentTop贴紧父元素的上边缘android:lay... 阅读全文
posted @ 2012-11-29 12:31 1小松 阅读(347) 评论(0) 推荐(0) 编辑