FileText
Gives you a file-like object for reading text, and you will get a str data from it. The default mode of this class is mode="r".
Constructor
Signature
def FileText(
args: Any,
kwargs: Any
) - > null
Parameters
| Name | Type | Description |
|---|---|---|
| args | Any | Positional arguments passed to the parent io.TextIOWrapper constructor. |
| kwargs | Any | Keyword arguments passed to the parent io.TextIOWrapper constructor, typically including 'mode'. |
Signature
def FileText(
buffer: io.BufferedIOBase,
encoding: str,
errors: str,
newline: str,
line_buffering: bool = False,
write_through: bool = False
) - > null
Parameters
| Name | Type | Description |
|---|---|---|
| buffer | io.BufferedIOBase | The underlying binary stream to wrap for text-based I/O operations. |
| encoding | str | The name of the encoding used to decode or encode the file contents. |
| errors | str | The error handling scheme to use for encoding and decoding errors. |
| newline | str | Controls how line endings are handled during text processing. |
| line_buffering | bool = False | Whether to enable line buffering for the text stream. |
| write_through | bool = False | Whether to bypass buffering and write directly to the underlying binary stream. |