public void RemoveExclude(EB.Sparx.Manager manager, string message) { if (m_excludes.ContainsKey(manager)) { message = message.ToLower(); List <string> excludes = m_excludes[manager]; excludes.Remove(message); if (excludes.Count == 0) { m_excludes.Remove(manager); } } }
private bool ShouldExclude(EB.Sparx.Manager manager, string message) { if (manager == null) { return(false); } if (!m_excludes.ContainsKey(manager)) { return(false); } message = message.ToLower(); List <string> excludes = m_excludes[manager]; return(excludes.Contains(message)); }
public void AddExclude(EB.Sparx.Manager manager, string message) { message = message.ToLower(); if (m_excludes.ContainsKey(manager)) { List <string> excludes = m_excludes[manager]; if (!excludes.Contains(message)) { excludes.Add(message); } } else { m_excludes[manager] = new List <string>() { message }; } }