@Override public String getString(String encoding) throws UnsupportedEncodingException { byte[] bytes = get(); return new String(bytes, encoding); }
@Override public String getName() { return getFileName(part); }
@Override public String getString() { try { return getString("UTF-8"); } catch (UnsupportedEncodingException uex) { throw new WicketRuntimeException("UTF-8 must be supported", uex); } }
@Override public byte[] get() { try { return IOUtils.toByteArray(getInputStream()); } catch (IOException iox) { throw new WicketRuntimeException("Could not read upload's part input stream", iox); } }
FileItem fileItem = new ServletPartFileItem(part); itemsFromParts.add(fileItem);
@Override public String getString() { try { return getString("UTF-8"); } catch (UnsupportedEncodingException uex) { throw new WicketRuntimeException("UTF-8 must be supported", uex); } }
@Override public byte[] get() { try { return IOUtils.toByteArray(getInputStream()); } catch (IOException iox) { throw new WicketRuntimeException("Could not read upload's part input stream", iox); } }
FileItem fileItem = new ServletPartFileItem(part); itemsFromParts.add(fileItem);
@Override public String getString(String encoding) throws UnsupportedEncodingException { byte[] bytes = get(); return new String(bytes, encoding); }
@Override public String getName() { return getFileName(part); }