DnSpyFile FindByKey_NoLock(IDnSpyFilenameKey key) { if (key == null) { return(null); } foreach (var file in files) { if (key.Equals(file.Key)) { return(file); } } return(null); }
IDnSpyFile Find_NoLock(IDnSpyFilenameKey key) { Debug.Assert(key != null); if (key == null) { return(null); } foreach (var file in files) { if (key.Equals(file.Key)) { return(file); } } return(null); }
IDnSpyFile Remove_NoLock(IDnSpyFilenameKey key) { if (key == null) { return(null); } for (int i = 0; i < files.Count; i++) { if (key.Equals(files[i].Key)) { files.RemoveAt(i); return(files[i]); } } return(null); }
public void Remove(IDnSpyFilenameKey key) { Debug.Assert(key != null); if (key == null) { return; } IDnSpyFile removedFile; lock (lockObj) removedFile = Remove_NoLock(key); Debug.Assert(removedFile != null); if (removedFile != null) { CallCollectionChanged(NotifyFileCollectionChangedEventArgs.CreateRemove(removedFile, null)); } }
DnSpyFile FindByKey_NoLock(IDnSpyFilenameKey key) { if (key == null) return null; foreach (var file in files) { if (key.Equals(file.Key)) return file; } return null; }
public DnSpyFile FindByKey(IDnSpyFilenameKey key) { lock (lockObj) return FindByKey_NoLock(key); }
DnSpyFile FindAssemblyByKey(IDnSpyFilenameKey key) { return(DnSpyFileList.FindByKey(key)); }
IDnSpyFile FindAssemblyByKey(IDnSpyFilenameKey key) => fileManager.Find(key);
IDnSpyFile Remove_NoLock(IDnSpyFilenameKey key) { if (key == null) return null; for (int i = 0; i < files.Count; i++) { if (key.Equals(files[i].Key)) { files.RemoveAt(i); return files[i]; } } return null; }
IDnSpyFile FindAssemblyByKey(IDnSpyFilenameKey key) { return fileManager.Find(key); }
IDnSpyFile Find_NoLock(IDnSpyFilenameKey key) { Debug.Assert(key != null); if (key == null) return null; foreach (var file in files) { if (key.Equals(file.Key)) return file; } return null; }
public void Remove(IDnSpyFilenameKey key) { Debug.Assert(key != null); if (key == null) return; IDnSpyFile removedFile; lock (lockObj) removedFile = Remove_NoLock(key); Debug.Assert(removedFile != null); if (removedFile != null) CallCollectionChanged(NotifyFileCollectionChangedEventArgs.CreateRemove(removedFile, null)); }
public IDnSpyFile Find(IDnSpyFilenameKey key) { lock (lockObj) return Find_NoLock(key); }
IDnSpyFile FindAssemblyByKey(IDnSpyFilenameKey key) { return(fileManager.Find(key)); }
public IDnSpyFile Find(IDnSpyFilenameKey key) { lock (lockObj) return(Find_NoLock(key)); }
DnSpyFile FindAssemblyByKey(IDnSpyFilenameKey key) { return DnSpyFileList.FindByKey(key); }
public DnSpyFile FindByKey(IDnSpyFilenameKey key) { lock (lockObj) return(FindByKey_NoLock(key)); }