private bool ValidDailyCodeChurn(DailyCodeChurn dailyCodeChurn) { if (dailyCodeChurn.GetDateTimeAsDateTime() < startDate || dailyCodeChurn.GetDateTimeAsDateTime() > endDate) { return(false); } if (!measureAggregator.HasValue(dailyCodeChurn)) { return(false); } return(true); }
private void ProcessLine(SortedDictionary <DateTime, AggregatedDailyCodeChurn> dict, DailyCodeChurn line, string fileWithoutPrefix) { if (!this.inclusionsProcessor.IsIncluded(fileWithoutPrefix)) { return; } if (this.exclusionsProcessor.IsExcluded(fileWithoutPrefix)) { return; } DateTime key = line.GetDateTimeAsDateTime().Date; if (!dict.ContainsKey(key)) { dict.Add(key, new AggregatedDailyCodeChurn() { Timestamp = key.ToString(AggregatedDailyCodeChurn.DATE_FORMAT, CultureInfo.InvariantCulture) }); } AggregateLine(dict[key], line); }