FileReader

Sequential reads of the immutable content captured at open time. Empty bytes mean EOF.

Properties

Link copied to clipboard
val path: Path
Link copied to clipboard

Functions

Link copied to clipboard
open override fun close()
Link copied to clipboard
fun lineSequence(maximumLineBytes: Int = 65536): Sequence<String>

Reads strict UTF-8 lines lazily from the current snapshot position. The caller must close this reader. Each sequence permits one traversal, including after exhaustion. Do not interleave binary reads or other sequences: line iteration reads ahead in bounded chunks. All iteration checks the reader lifetime.

Link copied to clipboard
fun read(maximumBytes: Int = 4095): ByteArray