示例#1
0
 public void Error(ILogContext context, string msg)
 {
     if (_settings.IsContextEnabled(context))
     {
         Debug.unityLogger.Log(LogType.Error, context.ToString(), msg);
     }
 }
示例#2
0
 public void ErrorFormat <T1, T2>(ILogContext context, string msg, T1 arg1, T2 arg2)
 {
     if (_settings.IsContextEnabled(context))
     {
         Debug.unityLogger.Log(LogType.Error, context.ToString(), string.Format(msg, arg1, arg2));
     }
 }
示例#3
0
 public void AssertFormat <T1, T2, T3, T4, T5>(ILogContext context, string msg, T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5)
 {
     if (_settings.IsContextEnabled(context))
     {
         Debug.unityLogger.Log(LogType.Assert, context.ToString(), string.Format(msg, arg1, arg2, arg3, arg4, arg5));
     }
 }
示例#4
0
 public void AssertFormat(ILogContext context, string msg, params object[] args)
 {
     if (_settings.IsContextEnabled(context))
     {
         Debug.unityLogger.Log(LogType.Assert, context.ToString(), string.Format(msg, args));
     }
 }
示例#5
0
 public void AssertFormat <T1>(ILogContext context, string msg, T1 arg1)
 {
     if (_settings.IsContextEnabled(context))
     {
         Debug.unityLogger.Log(LogType.Assert, context.ToString(), string.Format(msg, arg1));
     }
 }
示例#6
0
 public void WarningFormat <T1, T2, T3, T4>(ILogContext context, string msg, T1 arg1, T2 arg2, T3 arg3, T4 arg4)
 {
     if (_settings.IsContextEnabled(context))
     {
         Debug.unityLogger.Log(LogType.Warning, context.ToString(), string.Format(msg, arg1, arg2, arg3, arg4));
     }
 }
示例#7
0
 public void MessageFormat <T1, T2, T3>(ILogContext context, string msg, T1 arg1, T2 arg2, T3 arg3)
 {
     if (_settings.IsContextEnabled(context))
     {
         Debug.unityLogger.Log(LogType.Log, context.ToString(), string.Format(msg, arg1, arg2, arg3));
     }
 }
示例#8
0
        public void Log(LogLevel level, string message, ILogContext logContext, Exception exception = null)
        {
            var    objMessage = logContext.ToString();
            string logMessage = string.Format("Message: {0} {1} {2}", message, Environment.NewLine, objMessage);

            LogMessage(level, logMessage, exception);
        }
示例#9
0
        public void Log(LogLevel level, ILogContext logContext, Exception exception = null)
        {
            var logMessage = logContext.ToString();

            LogMessage(level, logMessage, exception);
        }