Class: LineStream
The io:LineStream
is used to initialize a stream of the type strings(lines). This io:LineStream
refers to the
stream that is embedded to the I/O character channels.
Constructor
Initialize an io:LineStream
using an io:ReadableCharacterChannel
.
init (ReadableCharacterChannel readableCharacterChannel)
- readableCharacterChannel ReadableCharacterChannel
The
io:ReadableCharacterChannel
that the line stream is referred to
Methods
next
Isolated Function
The next function reads and returns the next line of the related stream.
close
function close() returns Error?
Isolated Function
Closes the stream. The primary usage of this function is to close the stream without reaching the end
If the stream reaches the end, the LineStream.next()
will automatically close the stream.