java bufferedreader read line code example Example: java bufferedreader read all lines line = buffer.lines().collect(Collectors.joining());