码迷,mamicode.com
首页 > 其他好文 > 详细

设计模式之 Observer Pattern 观察者模式

时间:2014-12-12 16:30:31      阅读:151      评论:0      收藏:0      [点我收藏+]

标签:http   sp   on   bs   ad   as   tt   nbsp   设计   

bubuko.com,布布扣

 

1.Subject通过一个容器保存零到多个Observer。

2.Subject通过Add,Delete方法调整Observer。

3.Subject的notifyObservers方法实际是逐个调用容器中Observer的notify方法。

设计模式之 Observer Pattern 观察者模式

标签:http   sp   on   bs   ad   as   tt   nbsp   设计   

原文地址:http://www.cnblogs.com/fifila/p/4159904.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!