示例#1
0
        private List <BaseLogAnalyzer> buildAnalyzers(AnalysisArgs analysisArgs)
        {
            var analyzerBuilder = new AnalyzersBuilder(analysisArgs.AnalyzerConfigurations);
            var analyzers       = analyzerBuilder.BuildAnalyzers();

            addAdHocRegexAnalyzerIfNeeded(analyzers);
            return(analyzers);
        }
示例#2
0
        private List <AnalyzerShortCircuitChain> buildAnalyzerChains(AnalysisArgs analysisArgs)
        {
            var analyzerChains = new List <AnalyzerShortCircuitChain>();

            foreach (var chainConfig in analysisArgs.AnalyzerChainConfigurations)
            {
                var analyzerChain        = new AnalyzerShortCircuitChain(chainConfig.DisplayName);
                var analyzerChainBuilder = new AnalyzersBuilder(chainConfig.AnalyzerConfigurations.Where(ac => ac.Enabled).ToList());
                analyzerChain.Analyzers.AddRange(analyzerChainBuilder.BuildAnalyzers());
                analyzerChains.Add(analyzerChain);
            }
            return(analyzerChains);
        }