Esempio n. 1
0
 public override void Log(LogEntry entry)
 {
     if (entry.Level <= HighestLevel)
         if (this.UseCustomFormat)
             Console.WriteLine (entry.ToFormatString (this.CustomFormat));
         else
             Console.WriteLine (entry.ToString ());
 }
Esempio n. 2
0
        public override void Log(LogEntry entry)
        {
            checkFile ();

            if (entry.Level <= HighestLevel) {
                if (this.UseCustomFormat)
                    File.AppendAllLines (this.Filepath, new string[]{ entry.ToString () });
                else
                    File.AppendAllLines (this.Filepath, new string[]{ entry.ToFormatString (this.CustomFormat) });
            }
        }