public override void Format(TextWriter writer, LoggingEvent loggingEvent) { CsvTextWriter ctw = new CsvTextWriter(writer); // write the starting quote for the first field ctw.WriteQuote(); base.Format(ctw, loggingEvent); }
protected override void Convert(TextWriter writer, object state) { CsvTextWriter ctw = writer as CsvTextWriter; // write the ending quote for the last field if (ctw != null) { ctw.WriteQuote(); } writer.WriteLine(); }
protected override void Convert(TextWriter writer, object state) { CsvTextWriter ctw = writer as CsvTextWriter; // write the ending quote for the previous field if (ctw != null) { ctw.WriteQuote(); } writer.Write(','); // write the starting quote for the next field if (ctw != null) { ctw.WriteQuote(); } }