- All Known Subinterfaces:
- All Known Implementing Classes:
public interface InputBuffer
This class is only for internal use in the protocol implementation. All reading from Tomcat (or adapter) should be done using Request.doRead().
Method SummaryModifier and TypeMethodDescription
intObtain an estimate of the number of bytes that can be read without blocking.
(ApplicationBufferHandler handler)Read from the input stream into the ByteBuffer provided by the ApplicationBufferHandler.
(ApplicationBufferHandler handler) throws IOExceptionRead from the input stream into the ByteBuffer provided by the ApplicationBufferHandler. IMPORTANT: the current model assumes that the protocol will 'own' the ByteBuffer and return a pointer to it.
handler- ApplicationBufferHandler that provides the buffer to read data into.
- The number of bytes that have been added to the buffer or -1 for end of stream
IOException- If an I/O error occurs reading from the input stream
availableint available()Obtain an estimate of the number of bytes that can be read without blocking. Typically, this will be the number of available bytes known to be buffered.
- The number of bytes that can be read without blocking