2013年6月21日

摘要: Intent: Convert the interface of a class into another interface clients expect. Adapter lets classes work together that couldn't otherwise because of incompatible interfaces. 用于不同接口之间的转换。Structure: A class adapters uses multiple inheritance to adapter one interface to another. An object adapter 阅读全文
posted @ 2013-06-21 11:11 梦想改变生活 阅读(212) 评论(0) 推荐(0)

2013年4月3日

摘要: android系统中有个ContentService服务,定义了俩接口:IContentService,IContentObserver。ContentResolverr的register/unregister接口实现就是获取系统contentService服务,然后把ContentObserver中的IContentObserver的实现和Uri同时注册到ContentService服务中,当ContentProvider对象通知(notify)contentService服务某种Uri发生改变,CS会根据Uri查找到对应的IContentObserver对象,(IContentObserv 阅读全文
posted @ 2013-04-03 12:16 梦想改变生活 阅读(292) 评论(0) 推荐(0)

2013年3月29日

摘要: When you are building a house, you may choose to install a home entertainment system. It is possible to buy a single unit that includes everything: television screen, tuner, VCR, DVD player, and speakers. Such a system is easy to install and works great if it meets your needs. A one-piece unit is no 阅读全文
posted @ 2013-03-29 09:26 梦想改变生活 阅读(131) 评论(0) 推荐(0)
 
摘要: 本章开篇综述: 1.A component is a logical, replaceable part of a system that conforms to and provides the realization of a set of interfaces. 组件的目的是通过可替换的方法,实现相同的接口,构建灵活的系统。 2.Good components define crisp abstractions with well-defined interfaces, making it possible to easily replace older components ... 阅读全文
posted @ 2013-03-29 09:07 梦想改变生活 阅读(153) 评论(0) 推荐(0)

2011年12月18日

摘要: extent: Variable and functions, unlike types,have an existence at run time—that is,they have storage allocated to them. The extent of these objects is the period of time that the storage is allocate... 阅读全文
posted @ 2011-12-18 21:11 梦想改变生活 阅读(303) 评论(0) 推荐(0)

2011年12月3日

摘要: package mqiano.com.cnblogs;import java.util.Date;import java.util.GregorianCalendar;import static java.lang.System.out;public class Test {public static void main(String[] argu) {Manager mqiano = new Manager("mqiano", 10000, 2012, 7, 0); Manager mqianoo = new Manager("mqiano", 100 阅读全文
posted @ 2011-12-03 10:56 梦想改变生活 阅读(129) 评论(0) 推荐(0)