@ Override public String asText ( ) throws ParsableException { try ( BufferedReader reader = new BufferedReader ( new InputStreamReader ( request . getInputStream ( ) ) ) ) { return reader . lines ( ) . collect ( Collectors . joining ( ) ) ; } catch ( IOException e ) { throw new ParsableException ( "Reading the input failed" ) ; } }
Conveniently converts any input in the request into a string