private void Remove(ICollection podcasts) { if (podcasts == null) { throw new ArgumentNullException("podcasts"); } lock (podcasts.SyncRoot) { foreach (PodcastInfo pi in podcasts) { try { RemovePodcast(pi, false); } catch { continue; } } PodcastDBManager.Delete(podcasts) ; UpdateCounts(); } }
internal void Delete() { lock (podcasts.SyncRoot) { podcasts.Clear(); } PodcastDBManager.Delete(this); }
private void RemovePodcast(PodcastInfo pi, bool update) { if (pi == null) { throw new ArgumentNullException("pi"); } lock (podcasts.SyncRoot) { podcasts.Remove(pi); if (update) { PodcastDBManager.Delete(pi); UpdateCounts(); } } }