Package jakarta.servlet
Interface ReadListener
- All Superinterfaces:
- EventListener
Receives notification of read events when using non-blocking IO.
- Since:
- Servlet 3.1
- 
Method SummaryModifier and TypeMethodDescriptionvoidInvoked when the request body has been fully read.voidInvoked when data is available to read.voidInvoked if an error occurs while reading the request body.
- 
Method Details- 
onDataAvailableInvoked when data is available to read. The container will invoke this method the first time for a request as soon as there is data to read. Subsequent invocations will only occur if a call toServletInputStream.isReady()has returned false and data has subsequently become available to read.- Throws:
- IOException- id an I/O error occurs while processing the event
 
- 
onAllDataReadInvoked when the request body has been fully read.- Throws:
- IOException- id an I/O error occurs while processing the event
 
- 
onErrorInvoked if an error occurs while reading the request body.- Parameters:
- throwable- The exception that occurred
 
 
-