* @throws IllegalArgumentException if the input is null
* @throws IOException if an I/O error occurs, such as if the encoding is invalid
* @since 2.3
*/
public static LineIterator lineIterator(final InputStream input, final Charset encoding) throws IOException {
return new LineIterator(new InputStreamReader(input, Charsets.toCharset(encoding)));
}