public ServletInputStream getInputStream ( ) throws IOException { if ( TraceComponent . isAnyTracingEnabled ( ) && logger . isLoggable ( Level . FINE ) ) { logger . logp ( Level . FINE , CLASS_NAME , "getInputStream" , "this->" + this + ": gotReader = " + _srtRequestHelper . _gotReader ) ; } if ( WCCustomProperties . CHECK_REQUEST_OBJECT_IN_USE ) { checkRequestObjectInUse ( ) ; } // MultiRead Start // if stream is currently closed, allow re-read. // otherwise this must be the first read so register as an observer to be notified when close occurs. if ( this . multiReadPropertyEnabled ) { if ( _srtRequestHelper . _InputStreamClosed ) { ( ( SRTInputStream ) this . _in ) . restart ( ) ; } } if ( _srtRequestHelper . _gotReader ) throw new IllegalStateException ( liberty_nls . getString ( "Reader.already.obtained" , "Reader already obtained" ) ) ; // MultiRead End _srtRequestHelper . _gotInputStream = true ; if ( TraceComponent . isAnyTracingEnabled ( ) && logger . isLoggable ( Level . FINE ) ) { logger . logp ( Level . FINE , CLASS_NAME , "getInputStream" , "stream->" + _in + ": gotReader = " + _srtRequestHelper . _gotReader ) ; } return _in ; }
Returns an input stream for reading binary request data .