A TraceListener that writes to the Console

I keep writing this class over and over.  It’s quite handy.

class ConsoleWriter : System.Diagnostics.TraceListener {
  public override void Write(string message) {
    Console.Write(message);
  }
  public override void WriteLine(string message) {
    Console.WriteLine(message);
  }
}

Your post must include a link to this post.

How does this work?
Write a response on your own website and include a link to this post. Then submit your response’s URL here. Your response may appear here after moderation. To update or remove it, edit or delete your original post and submit the same URL again. Learn more about Webmentions.