/// <summary> /// Write a trace event to ApplicationInsights. /// </summary> public void TraceEvent( LogLevel logLevel, EventId eventId, string message, [CallerMemberName] string member = null, [CallerFilePath] string file = null, [CallerLineNumber] int line = 0) { if (string.IsNullOrEmpty(message)) { throw new ArgumentException( string.Format(CultureInfo.CurrentCulture, ServicesStrings.ParameterCannotBeNullOrEmpty, nameof(message)), nameof(message)); } _telemetryClient.TrackTrace(FormatMessage(message, member, file, line), logLevel, eventId); }
private void TrackTraceCore(string message, TraceSeverity severity, Dictionary <string, string> data) { _client.TrackTrace(message, severity, data); }