public virtual void WriteTo(Stream output, Encoding encoding) { using(var sw = new StreamWriter(output, encoding)) WriteTo(sw); }