private static StringBuilder AddCommentsForStatus(this StringBuilder report, BulkSolutionsAnalysisRunStatistics statistics, string status) { if (statistics.CommentsWithCount.Count == 0) { return(report); } var maxCommentLength = statistics.CommentsWithCount.Keys.Max(comment => comment.Length); report .AppendLine() .AddCommentsForStatusHeader(status) .AppendLine($"| {"Comment".PadRight(maxCommentLength, ' ')} | {"Count".PadRight(CommentsCountColumnWidth, ' ')} |") .AppendLine($"| {"".PadRight(maxCommentLength, '-')}:| {"".PadRight(CommentsCountColumnWidth, '-')}:|"); foreach (var commentWithCount in statistics.CommentsWithCount) { report.AddCommentCount(commentWithCount, maxCommentLength); } return(report); }
private static StringBuilder AddStatisticsForStatus(this StringBuilder report, BulkSolutionsAnalysisRunStatistics statistics, string status) => report.AppendLine($"| {status,StatisticsStatusColumnWidth} | {statistics.Count,StatisticsCountColumnWidth} | {statistics.CommentsWithCount.Count,StatisticsCommentsColumnWidth} | {statistics.Performance.AverageInMilliseconds,4:#0}ms | {statistics.Performance.TotalInMilliseconds,6:#0}ms | ");