Example #1
0
 /// <summary>
 /// 将订阅者ob从该订阅号的通知列表中移除
 /// </summary>
 /// <param name="ob">订阅者</param>
 public virtual void Detach(YuriObserver ob)
 {
     lock (this)
     {
         this.observers.Remove(ob);
     }
 }
Example #2
0
 /// <summary>
 /// 将订阅者ob加入该订阅号的通知列表
 /// </summary>
 /// <param name="ob">订阅者</param>
 public virtual void Attach(YuriObserver ob)
 {
     lock (this)
     {
         this.observers.Add(ob);
     }
 }