Esempio n. 1
0
        /// <summary>
        /// Trace error message.
        /// </summary>
        /// <param name="exception">Indicating the exception.</param>
        /// <param name="message">Indicating the message.</param>
        /// <param name="args">Indicating the message arguments.</param>
        public static void TraceError(Exception exception, string message, params object[] args)
        {
            if (string.IsNullOrEmpty(message))
            {
                message = exception.ToString();
            }
            else
            {
                message = FormatMessage(message, args);
                if (exception != null)
                {
                    message = FormatMessage("{0}, Exception: {1}", message, exception);
                }
            }

            adapter.TraceError(message);
        }