Ejemplo n.º 1
0
        void CvsLogsFilter(object sender, FilterEventArgs e)
        {
            LogMessageViewModel vm = (LogMessageViewModel)e.Item;

            //first of all filter for exact level.
            if (LevelFilter > 0 && vm.Log.NumericLevel < LevelFilter)
            {
                e.Accepted = false;
                return;
            }
            //now filter for main filter
            if (!String.IsNullOrEmpty(MainFilter))
            {
                e.Accepted = vm.Log.Message.Contains(MainFilter, StringComparison.OrdinalIgnoreCase) ||
                             vm.Log.Logger.Contains(MainFilter, StringComparison.OrdinalIgnoreCase);
            }
        }
Ejemplo n.º 2
0
        private void LogsFilter(object sender, FilterEventArgs e)
        {
            LogMessageViewModel vm = (LogMessageViewModel)e.Item;

            e.Accepted = LoggerName.Equals(vm.Log.Logger, StringComparison.OrdinalIgnoreCase);
        }