BlueCollar.EventLogger.RaiseLog C# (CSharp) Method

RaiseLog() private method

Raises the Log event on this instance.
private RaiseLog ( EventLoggerEventType eventType, Exception ex, string format ) : void
eventType EventLoggerEventType The event type to raise.
ex System.Exception The exception to raise the event for, if applicable.
format string The message format to use.
return void
        private void RaiseLog(EventLoggerEventType eventType, Exception ex, string format, params object[] args)
        {
            if (this.Log != null)
            {
                string message = null;

                if (!string.IsNullOrEmpty(format))
                {
                    message = string.Format(CultureInfo.InvariantCulture, format, args);
                }

                this.Log(this, new EventLoggerEventArgs(eventType, message, ex));
            }
        }