public void RemoveWriteRequest(TNDWriteRequest theRequest) { // lock (masterListLock) using (TimedLock.Lock(masterListLock)) { mWriteRequests_all.Remove(theRequest); if (theRequest.Active) { mTagListDirty = true; } } }
public void AddWriteRequest(TNDWriteRequest theRequest) { if (!Connected) { Connected = true; } // lock (masterListLock) using (TimedLock.Lock(masterListLock)) { if (mWriteRequests_all.Contains(theRequest)) { throw new ArgumentException("How did we get here?"); } mWriteRequests_all.Add(theRequest); if (theRequest.Active) { mTagListDirty = true; } } }