klyn.io.FileReader.read
method
public read() as String throws IOException
Description

Reads all remaining text from the current reader position.

read() is a compact alias for readAllText().

Returns

Remaining text.

Throws
  • IOException if the resource is closed, inaccessible, not a valid file, or the underlying I/O operation fails.
Example
try reader = FileReader("notes.txt", encoding="utf-8"):
    content = reader.read()