@Override public void close() throws IOException { if (file != null) { file.delete(); } upload.delete(); }
@Override public void cleanupMultipart(MultipartHttpServletRequest request) { if (!(request instanceof AbstractMultipartHttpServletRequest) || ((AbstractMultipartHttpServletRequest) request).isResolved()) { // To be on the safe side: explicitly delete the parts, // but only actual file parts (for Resin compatibility) try { for (Part part : request.getParts()) { if (request.getFile(part.getName()) != null) { part.delete(); } } } catch (Throwable ex) { LogFactory.getLog(getClass()).warn("Failed to perform cleanup of multipart items", ex); } } }
@Override public void cleanupMultipart(MultipartHttpServletRequest request) { if (!(request instanceof AbstractMultipartHttpServletRequest) || ((AbstractMultipartHttpServletRequest) request).isResolved()) { // To be on the safe side: explicitly delete the parts, // but only actual file parts (for Resin compatibility) try { for (Part part : request.getParts()) { if (request.getFile(part.getName()) != null) { part.delete(); } } } catch (Throwable ex) { LogFactory.getLog(getClass()).warn("Failed to perform cleanup of multipart items", ex); } } }
/** * Deletes the underlying storage for a file item, including deleting any * associated temporary disk file. * * @throws IOException if an error occurs. */ public void delete() throws IOException { part.delete(); }
@Override public void delete() throws IOException { part.delete(); }
public static void clearPartResource(Part part) { if (FilePartForSend.class.isInstance(part) && ((FilePartForSend) part).isDeleteAfterFinished()) { try { part.delete(); } catch (IOException e) { LOGGER.error("Failed to delete temp file: {}.", ((FilePartForSend) part).getAbsolutePath(), e); } } } }
/** * Deletes the underlying storage for a file item, including deleting any * associated temporary disk file. * * @throws IOException if an error occurs. */ public void delete() throws IOException { part.delete(); }
@Override public void delete() throws IOException { synchronized(lock) { part.delete(); } }
@Override public void delete() throws IOException { part.delete(); }
public void delete() throws IOException { part.delete(); }
@Override public void close() throws IOException { if (file != null) { file.delete(); } upload.delete(); }
part.delete(); } catch (Exception e) { array.add(addError(name, size, "ERROR"));
@Override public void delete() throws IOException { getWrapped().delete(); }
@Override public void delete() { try { part.delete(); } catch (IOException iox) { throw new WicketRuntimeException("A problem occurred while deleting an upload part", iox); } }
@Override public void delete() { try { part.delete(); } catch (IOException iox) { throw new WicketRuntimeException("A problem occurred while deleting an upload part", iox); } }
@Override public void delete() throws IOException { getWrapped().delete(); }
public void delete() throws IOException { getWrapped().delete(); }
public static void clearPartResource(Part part) { if (FilePartForSend.class.isInstance(part) && ((FilePartForSend) part).isDeleteAfterFinished()) { try { part.delete(); } catch (IOException e) { LOGGER.error("Failed to delete temp file: {}.", ((FilePartForSend) part).getAbsolutePath(), e); } } } }
public void discardPrefailedFile(byte[] buffer) throws IOException { partsManualProgress.updateRead(part.getSize()); part.delete(); }
@Override public void cleanupMultipart(MultipartHttpServletRequest request) { // To be on the safe side: explicitly delete the parts, // but only actual file parts (for Resin compatibility) try { for (Part part : request.getParts()) { if (request.getFile(part.getName()) != null) { part.delete(); } } } catch (Exception ex) { if (log.isWarnEnabled()) { log.warn("Failed to perform cleanup of multipart items", ex); } } }