/** * This feature is not implemented at this time as we are not supporting binary servlet input. * This functionality may be added in the future. * * @return The reader * @throws IOException * If an I/O related problem occurs */ @Override public BufferedReader getReader() throws IOException { return new BufferedReader(new InputStreamReader(getInputStream())); }
/** * This feature is not implemented at this time as we are not supporting binary servlet input. * This functionality may be added in the future. * * @return The reader * @throws IOException * If an I/O related problem occurs */ @Override public BufferedReader getReader() throws IOException { return new BufferedReader(new InputStreamReader(getInputStream())); }
@Override public ServletInputStream getInputStream() throws IOException { if(content==null) return super.getInputStream(); else { final StringReader sr = new StringReader(content); return new ServletInputStream() { @Override public int read() throws IOException { return sr.read(); } }; } } };