TextFileContent Class
Holds the text of a file, and the encoding to write the file back with.
public sealed class TextFileContentSee also
Constructors
| Name | Description |
|---|---|
| TextFileContent(string, Encoding) | Initializes a new instance of the TextFileContent class. |
TextFileContent(string, Encoding)
Initializes a new instance of the TextFileContent class.
Properties
| Name | Description |
|---|---|
| Encoding | Gets the encoding to write the file back with. |
| Text | Gets the text of the file. |
Encoding
Gets the encoding to write the file back with.
public Encoding Encoding { get; }Property value
Encoding For a content that TextFileUtility.ReadAllText returns, the encoding of the byte order mark of the file, or the fallback encoding if the file has none.
Text
Methods
| Name | Description |
|---|---|
| Deconstruct(string, Encoding) | Deconstructs this instance into the text of the file and the encoding to write the file back with. |
Deconstruct(string, Encoding)
Deconstructs this instance into the text of the file and the encoding to write the file back with.
Parameters
textstring- When this method returns, the value of
TextFileContent.Text. encodingEncoding- When this method returns, the value of
TextFileContent.Encoding.