博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

2012年1月5日

摘要: 模板方法:封装算法 – 泡咖啡,茶 模板方法定义了一个算法的步骤,并允许子类为一个或多个步骤提供实现 迭代器与组合 - 菜单 管理良好的集合 迭代器:hasNext();next();remove(); 组合:允许你将对象组合成树形结构来表现“整体/部分”层次结构。组合能让客户以一致的方式处理个别对象以及对象组合。 状态模式 - 糖果机 状态模式允许对象在内部状态改变时... 阅读全文

posted @ 2012-01-05 23:46 theok 阅读(106) 评论(0) 推荐(0)

2011年12月31日

摘要: 找出应用中可能需要变化之处,把它们独立出来,不要和那些不需要变化的代码混在一起。 把会变化的部分取出并封装起来,以便以后可以轻易地改动或扩充此部分,而不影响不需要变化的其他部分。 把不变的放在接口里,而变化放在实现里。 针对接口(超类型)编程,而不是针对实现编程。 多用组合,少用继承。 类应该对扩展开发,对修改关... 阅读全文

posted @ 2011-12-31 17:56 theok 阅读(156) 评论(0) 推荐(0)

2011年12月27日

摘要: SummaryModel Driven Design express model with ServicesModel Driven Design express model with EntitiesModel Driven Design express model with Value ObjectsModel Driven Design isolate domain with Layered ArchitectureEntities access with RepositoriesAggregates access with RespositoriesEntities maintain 阅读全文

posted @ 2011-12-27 10:25 theok 阅读(196) 评论(0) 推荐(0)

2011年12月17日

摘要: 阅读全文

posted @ 2011-12-17 21:47 theok 阅读(116) 评论(0) 推荐(0)

2011年11月19日

摘要: WLW 阅读全文

posted @ 2011-11-19 23:04 theok 阅读(80) 评论(0) 推荐(0)

2011年8月18日

摘要: 有谁跟我一样恨不得干掉IE的?好了,吐槽完上代码。Code var g_ifm = null; var g_layer = null; var g_isCreated = false; var cssIfr = 'display:none;position:absolute;left:0;top:0;width:0;height:0;overflow:hidden;background:#fff;z-index:100;border:none;'; var cssLayer = 'display:none;position:absolute;left:0;top:0;w 阅读全文

posted @ 2011-08-18 23:28 theok 阅读(199) 评论(0) 推荐(0)

2010年11月30日

摘要: CSS FoundationIgnore this because i believe that we should use our own styles for our website ;)YUI’s Core JavaScript ComponentsDom CollectionUsing setXY POS: ../yui/examples/dom/setxy.html这是个很有... 阅读全文

posted @ 2010-11-30 14:10 theok 阅读(221) 评论(0) 推荐(0)