예제 #1
0
 private static void writeLog(this ServiceBaseApplication app, NFX.Log.MessageType type, string text)
 {
     app.Log.Write(new NFX.Log.Message {
         Type = type,
         From = LOG_FROM_BOOTLOADER,
         Text = "Entering agni app bootloader..."
     });
 }
예제 #2
0
 private void log(NFX.Log.MessageType tp, string from, string text, Exception error = null, Guid?related = null)
 {
     App.Log.Write(new NFX.Log.Message
     {
         Type      = tp,
         Topic     = SysConsts.LOG_TOPIC_WMSG,
         From      = "{0}.{1}".Args(GetType().Name, from),
         Text      = text,
         Exception = error,
         RelatedTo = related ?? Guid.Empty
     });
 }
예제 #3
0
        protected void Log(MessageType type, string from, string text, Exception error = null, Guid?related = null)
        {
            var msg = new NFX.Log.Message
            {
                Type      = type,
                Topic     = SysConsts.LOG_TOPIC_APP_MANAGEMENT,
                From      = "{0}.{1}".Args(GetType().FullName, from),
                Text      = text,
                Exception = error
            };

            if (related.HasValue)
            {
                msg.RelatedTo = related.Value;
            }

            App.Log.Write(msg);
        }