// With Log Prefix and delegate to add custom logging info public void MethodDebugFormat(string logPrefix, LogOutputMapper customLogOutput, string format, params object[] args) { StringBuilder additionalLogData = new StringBuilder(); if (customLogOutput != null) { customLogOutput(additionalLogData); } log.DebugFormat(string.Format("{0}| Page: {3}, MethodName: {2}, {1}, {4}", logPrefix, format, GetDebugCallingMethod(), GetDebugCallingPage(), additionalLogData.ToString()), args); }
// With Log Prefix and delegate to add custom logging info public void MethodDebugFormat(string logPrefix, LogOutputMapper customLogOutput, string format, params object[] args) { if (log.IsDebugEnabled) { StringBuilder additionalLogData = new StringBuilder(); if (customLogOutput != null) customLogOutput(additionalLogData); log.DebugFormat(string.Format("{0}| Page: {3}, MethodName: {2}, {1}, {4}", logPrefix, format, GetDebugCallingMethod(), GetDebugCallingPage(), additionalLogData.ToString()), args); } }