docs: @Nonnull
      public List<String> getRemainingLines(boolean trimAndSkipEmpty) throws IOException {
          List<String> out = new ArrayList<>();
  
          StringBuilder builder = new StringBuilder();
          while (bufferOffset <= bufferLimit || !bufferLineEnd) {
              if (!readNextChar()) {
                  break;
              }
              if (lastChar == '\n') {
                  String line = builder.toString();
                  if (!trimAndSkipEmpty || !line.trim().isEmpty()) {
                      out.add(trimAndSkipEmpty ? line.trim() : line);
                  }
                  builder = new StringBuilder();
              } else {
                  builder.append((char) lastChar);
              }
          }
          if (builder.length() > 0) {
              String line = builder.toString();
              if (!trimAndSkipEmpty || !line.trim().isEmpty()) {
                  out.add(builder.toString());
              }
          }
          return out;
      }