Reading from a file with `File.readLines` is disco...
# server
e
Reading from a file with
File.readLines
is discouraged for big files. I suppose is just because it builds a
List
so of course a
Sequence
is preferred. But, does this advice apply also to:
val stream: Flow<String> = File(arguments.filename).readLines().asFlow()
? Not sure if the composer maybe optimise this to not have the full list before flowing,...
f
c
Probably want something like forEachLine()
e
Will take a look, thanks