/** * Fill the internal buffer using data from the underlying input stream. * * @return false if at end of stream */ protected boolean fill() throws IOException { return fill(true); }
/** * Fill the internal buffer using data from the underlying input stream. * * @return false if at end of stream */ protected boolean fill() throws IOException { return fill(true); }
/** * Fill the internal buffer using data from the underlying input stream. * * @return false if at end of stream */ protected boolean fill() throws IOException { return fill(true); }
/** * Fill the internal buffer using data from the underlying input stream. * * @return false if at end of stream */ protected boolean fill() throws IOException { return fill(true); }
/** * Read bytes into the specified chunk. */ @Override public int doRead(ByteChunk chunk, Request req ) throws IOException { if (pos >= lastValid) { if (!fill()) return -1; } int length = lastValid - pos; chunk.setBytes(buf, pos, length); pos = lastValid; return (length); } }
/** * Read bytes into the specified chunk. */ public int doRead(ByteChunk chunk, Request req ) throws IOException { if (pos >= lastValid) { if (!fill()) return -1; } int length = lastValid - pos; chunk.setBytes(buf, pos, length); pos = lastValid; return (length); }
/** * Read bytes into the specified chunk. */ public int doRead(ByteChunk chunk, Request req ) throws IOException { if (pos >= lastValid) { if (!fill()) return -1; } int length = lastValid - pos; chunk.setBytes(buf, pos, length); pos = lastValid; return (length); }
/** * Read bytes into the specified chunk. */ public int doRead(ByteChunk chunk, Request req ) throws IOException { if (pos >= lastValid) { if (!fill()) return -1; } int length = lastValid - pos; chunk.setBytes(buf, pos, length); pos = lastValid; return (length); }
/** * Read bytes into the specified chunk. */ @Override public int doRead(ByteChunk chunk, Request req ) throws IOException { if (pos >= lastValid) { if (!fill()) return -1; } int length = lastValid - pos; chunk.setBytes(buf, pos, length); pos = lastValid; return (length); }
/** * Read bytes into the specified chunk. */ @Override public int doRead(ByteChunk chunk, Request req ) throws IOException { if (pos >= lastValid) { if (!fill()) return -1; } int length = lastValid - pos; chunk.setBytes(buf, pos, length); pos = lastValid; return (length); } }
/** * Read bytes into the specified chunk. */ @Override public int doRead(ByteChunk chunk, Request req ) throws IOException { if (pos >= lastValid) { if (!fill()) return -1; } int length = lastValid - pos; chunk.setBytes(buf, pos, length); pos = lastValid; return (length); } }
private void skipLine(int start) throws IOException { boolean eol = false; int lastRealByte = start; if (pos - 1 > start) { lastRealByte = pos - 1; } while (!eol) { // Read new bytes if needed if (pos >= lastValid) { if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); } if (buf[pos] == Constants.CR) { // Skip } else if (buf[pos] == Constants.LF) { eol = true; } else { lastRealByte = pos; } pos++; } if (log.isDebugEnabled()) { log.debug(sm.getString("iib.invalidheader", new String(buf, start, lastRealByte - start + 1, Charset.forName("ISO-8859-1")))); } }
if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error"));
private void skipLine(int start) throws IOException { boolean eol = false; int lastRealByte = start; if (pos - 1 > start) { lastRealByte = pos - 1; } while (!eol) { // Read new bytes if needed if (pos >= lastValid) { if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); } if (buf[pos] == Constants.CR) { // Skip } else if (buf[pos] == Constants.LF) { eol = true; } else { lastRealByte = pos; } pos++; } if (log.isDebugEnabled()) { log.debug(sm.getString("iib.invalidheader", new String(buf, start, lastRealByte - start + 1, Charset.forName("ISO-8859-1")))); } }
if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error"));
if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error"));
private void skipLine(int start) throws IOException { boolean eol = false; int lastRealByte = start; if (pos - 1 > start) { lastRealByte = pos - 1; } while (!eol) { // Read new bytes if needed if (pos >= lastValid) { if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); } if (buf[pos] == Constants.CR) { // Skip } else if (buf[pos] == Constants.LF) { eol = true; } else { lastRealByte = pos; } pos++; } if (log.isDebugEnabled()) { log.debug(sm.getString("iib.invalidheader", new String(buf, start, lastRealByte - start + 1, StandardCharsets.ISO_8859_1))); } }
if (!inputBuffer.fill()) { throw new EOFException(sm.getString("iib.eof.error"));
if (!inputBuffer.fill()) { throw new EOFException(sm.getString("iib.eof.error"));
if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error")); if (!fill()) throw new EOFException(sm.getString("iib.eof.error"));