/** * Checks, whether the reader contains a next line. Returns false if the end * of the stream has been reached. * * @return true, if there is a next line to read, false otherwise. * @throws IOException if an error occures. */ public boolean hasNext() throws IOException { if (this.buffer == null) { this.buffer = readLine(); } return this.buffer != null; }
/** * Checks, whether the reader contains a next line. Returns false if the end * of the stream has been reached. * * @return true, if there is a next line to read, false otherwise. * @throws IOException if an error occures. */ public boolean hasNext() throws IOException { if (this.buffer == null) { this.buffer = readLine(); } return this.buffer != null; }
/** * Checks, whether the reader contains a next line. Returns false if the end * of the stream has been reached. * * @return true, if there is a next line to read, false otherwise. * @throws IOException if an error occures. */ public boolean hasNext() throws IOException { if (this.buffer == null) { this.buffer = readLine(); } return this.buffer != null; }