readUTF8LineTo

suspend fun ByteReadChannel.readUTF8LineTo(out: Appendable, max: Int = Int.MAX_VALUE): Boolean

Reads a line of UTF-8 characters to the specified out buffer. It recognizes CR, LF and CRLF as a line delimiter.

Return

true if a new line separator was found or max bytes appended. false if no new line separator and no bytes read.

Parameters

out

the buffer to write the line to

max

the maximum number of characters to read