예제 #1
0
 public void Remove(Kehu kehu)
 {
     this._lock.AcquireWriterLock(0);
     try
     {
         this._kehuList.Remove(kehu);
     }
     finally
     {
         this._lock.ReleaseWriterLock();
     }
 }
예제 #2
0
 public List <Dingdan> GetDingdan(Kehu kehu)
 {
     this._lock.AcquireReaderLock(0);
     try
     {
         return(this._dingdanList.Where(d => d.Kehu == kehu).ToList());
     }
     finally
     {
         this._lock.ReleaseReaderLock();
     }
 }