/// <summary> /// Adds <paramref name="stats"/> to the current <see cref="Timing"/>. /// </summary> internal void AddSqlTiming(SqlTiming stats) { if (Head == null) { return; } stats.IsDuplicate = _sqlExecutionCounts.TryGetValue(stats.CommandString, out int count); _sqlExecutionCounts[stats.CommandString] = count + 1; HasSqlTimings = true; if (stats.IsDuplicate) { HasDuplicateSqlTimings = true; } Head.AddSqlTiming(stats); }