Example #1
0
 /// <summary>
 /// Write entry to log
 /// </summary>
 /// <param name="message">Message to log</param>
 /// <param name="obj">Object to describe</param>
 public static void Write(String message, object obj)
 {
     lock (fileLock)
     {
         openLog();
         writeLog(message);
         try
         {
             ObjectDescriptor descriptor = new ObjectDescriptor(logWriter);
             descriptor.Describe(obj);
         }
         catch (Exception e)
         {
             writeLog(LogError);
             writeLog(describeException(e));
         }
         closeLog();
     }
 }