code: public static LineIterator iterate(final InputStream input, final Charset encoding) throws UncheckedIOException {
          return new LineIterator(createReader(input, encoding));
      }
docs: Returns an Iterator for the lines in an <code>InputStream</code>, using
  the character encoding specified (or default encoding if null).
  <p>
  <code>LineIterator</code> holds a reference to the open
  <code>InputStream</code> specified here. When you have finished with
  the iterator you should close the stream to free internal resources.
  This can be done by closing the stream directly, or by calling
  {@link LineIterator#close()} or {@link IOUtil#closeQuietly(LineIterator)}.
  <p>
  The recommended usage pattern is:
  <pre>
  try {
  LineIterator it = iterate(stream, charset);
  while (it.hasNext()) {
  String line = it.nextLine();
  /// do something with line
  }
  } finally {
  closeQuietly(stream);
  }
  </pre>
  
  @param input  the <code>InputStream</code> to read from, not null
  @param encoding  the encoding to use, null means platform default
  @return an Iterator of the lines in the reader, never null
  @throws IllegalArgumentException if the input is null
  @throws UncheckedIOException if an I/O error occurs, such as if the encoding is invalid