/** * Read a delimiter from the stream. * * @param delimiter * the delimiter to read. * @throws IOException */ private void readDelimiter(char delimiter) throws IOException { if (this.isEndOfFile()) { throw new EOFException(SR.LOG_STREAM_END_ERROR); } else { int read = this.read(); if (read == -1 || (char) read != delimiter) { throw new IllegalStateException(SR.LOG_STREAM_DELIMITER_ERROR); } } }
/** * Read a delimiter from the stream. * * @param delimiter * the delimiter to read. * @throws IOException */ private void readDelimiter(char delimiter) throws IOException { if (this.isEndOfFile()) { throw new EOFException(SR.LOG_STREAM_END_ERROR); } else { int read = this.read(); if (read == -1 || (char) read != delimiter) { throw new IllegalStateException(SR.LOG_STREAM_DELIMITER_ERROR); } } }
/** * Checks to see if the next character is the delimiter expected. * * @param delimiter * the delimiter to try to peek. * @return * @throws IOException */ private boolean tryPeekDelimiter(char delimiter) throws IOException { if (this.isEndOfFile()) { throw new EOFException(SR.LOG_STREAM_END_ERROR); } else { if ((char) this.peek() != delimiter) { return false; } else { return true; } } }
/** * Checks to see if the next character is the delimiter expected. * * @param delimiter * the delimiter to try to peek. * @return * @throws IOException */ private boolean tryPeekDelimiter(char delimiter) throws IOException { if (this.isEndOfFile()) { throw new EOFException(SR.LOG_STREAM_END_ERROR); } else { if ((char) this.peek() != delimiter) { return false; } else { return true; } } }
while (true) { if (this.isEndOfFile()) { throw new EOFException(SR.LOG_STREAM_END_ERROR);
while (true) { if (this.isEndOfFile()) { throw new EOFException(SR.LOG_STREAM_END_ERROR);
if (this.reader == null || this.reader.isEndOfFile()) {
if (this.reader == null || this.reader.isEndOfFile()) {