예제 #1
0
 public void AttachFilter(ISynchronizedViewFilter <T, TView> filter)
 {
     lock (SyncRoot)
     {
         this.filter = filter;
         foreach (var(value, view) in ringBuffer)
         {
             filter.InvokeOnAttach(value, view);
         }
     }
 }
예제 #2
0
 public void AttachFilter(ISynchronizedViewFilter <KeyValuePair <TKey, TValue>, TView> filter)
 {
     lock (SyncRoot)
     {
         this.filter = filter;
         foreach (var v in dict)
         {
             filter.InvokeOnAttach(new KeyValuePair <TKey, TValue>(v.Key, v.Value.Item1), v.Value.Item2);
         }
     }
 }