Class PlainTextWriter
Writes the DocWright document model as plain text.
public sealed class PlainTextWriter : IDocumentWriter
- Inheritance
-
PlainTextWriter
- Implements
- Inherited Members
Remarks
This is the most lossy writer in the tree and the losses need no enumeration to be obvious: plain text carries characters and line endings and nothing else. What is enumerated in COMPAT.md instead is the handful of choices that are not obvious — how a page break, a table, a header and a footnote are represented, all of which have more than one defensible answer and all of which are options.
Output is deterministic: byte-identical across runs and across the four target frameworks for the same input and options. The line ending is a fixed default rather than the platform's, which is what makes that true.
Constructors
- PlainTextWriter()
Initializes a writer with default options.
- PlainTextWriter(PlainTextWriteOptions)
Initializes a writer with format-specific options.
Properties
- Format
Gets the format this writer produces.
Methods
- Write(IDocWrightDocument, Stream, DocumentWriteOptions, IConversionDiagnostics)
Writes the document to the stream.