/** * {@inheritDoc} */ public void deleteFile(String filePath) throws FileSystemException { fsBase.deleteFile(buildBasePath(filePath)); }
/** * {@inheritDoc} */ public void deleteFile(String filePath) throws FileSystemException { fsBase.deleteFile(buildBasePath(filePath)); }
/** * {@inheritDoc} */ public void deleteFile(String filePath) throws FileSystemException { fsBase.deleteFile(buildBasePath(filePath)); }
/** * {@inheritDoc} */ public synchronized void destroy(NodeReferences refs) throws ItemStateException { if (!initialized) { throw new IllegalStateException("not initialized"); } try { StringBuffer buf = buildNodeReferencesFilePath(null, refs.getTargetId()); itemFs.deleteFile(buf.toString()); } catch (Exception e) { if (e instanceof NoSuchItemStateException) { throw (NoSuchItemStateException) e; } String msg = "failed to delete " + refs; BundleFsPersistenceManager.log.error(msg, e); throw new ItemStateException(msg, e); } }
/** * {@inheritDoc} */ public synchronized void destroy(NodeReferences refs) throws ItemStateException { if (!initialized) { throw new IllegalStateException("not initialized"); } try { StringBuffer buf = buildNodeReferencesFilePath(null, refs.getTargetId()); itemFs.deleteFile(buf.toString()); } catch (Exception e) { if (e instanceof NoSuchItemStateException) { throw (NoSuchItemStateException) e; } String msg = "failed to delete " + refs; BundleFsPersistenceManager.log.error(msg, e); throw new ItemStateException(msg, e); } }
/** * {@inheritDoc} */ protected synchronized void destroyBundle(NodePropBundle bundle) throws ItemStateException { try { StringBuffer buf = buildNodeFilePath(null, bundle.getId()); itemFs.deleteFile(buf.toString()); } catch (Exception e) { if (e instanceof NoSuchItemStateException) { throw (NoSuchItemStateException) e; } String msg = "failed to delete bundle: " + bundle.getId(); BundleFsPersistenceManager.log.error(msg, e); throw new ItemStateException(msg, e); } }
/** * {@inheritDoc} */ protected synchronized void destroyBundle(NodePropBundle bundle) throws ItemStateException { try { StringBuffer buf = buildNodeFilePath(null, bundle.getId()); itemFs.deleteFile(buf.toString()); } catch (Exception e) { if (e instanceof NoSuchItemStateException) { throw (NoSuchItemStateException) e; } String msg = "failed to delete bundle: " + bundle.getId(); BundleFsPersistenceManager.log.error(msg, e); throw new ItemStateException(msg, e); } }
blobFS.deleteFile(file);
blobFS.deleteFile(file);
/** * Deletes this resource. * * @param pruneEmptyParentDirs if <code>true</code>, empty parent folders will * automatically be deleted * @see FileSystem#deleteFile */ public synchronized void delete(boolean pruneEmptyParentDirs) throws FileSystemException { fs.deleteFile(path); if (pruneEmptyParentDirs) { // prune empty parent folders String parentDir = FileSystemPathUtil.getParentDir(path); while (!parentDir.equals(FileSystem.SEPARATOR) && fs.exists(parentDir) && !fs.hasChildren(parentDir)) { fs.deleteFolder(parentDir); parentDir = FileSystemPathUtil.getParentDir(parentDir); } } }
/** * Deletes this resource. * * @param pruneEmptyParentDirs if <code>true</code>, empty parent folders will * automatically be deleted * @see FileSystem#deleteFile */ public synchronized void delete(boolean pruneEmptyParentDirs) throws FileSystemException { fs.deleteFile(path); if (pruneEmptyParentDirs) { // prune empty parent folders String parentDir = FileSystemPathUtil.getParentDir(path); while (!parentDir.equals(FileSystem.SEPARATOR) && fs.exists(parentDir) && !fs.hasChildren(parentDir)) { fs.deleteFolder(parentDir); parentDir = FileSystemPathUtil.getParentDir(parentDir); } } }
/** * Deletes this resource. * * @param pruneEmptyParentDirs if <code>true</code>, empty parent folders will * automatically be deleted * @see FileSystem#deleteFile */ public synchronized void delete(boolean pruneEmptyParentDirs) throws FileSystemException { fs.deleteFile(path); if (pruneEmptyParentDirs) { // prune empty parent folders String parentDir = FileSystemPathUtil.getParentDir(path); while (!parentDir.equals(FileSystem.SEPARATOR) && fs.exists(parentDir) && !fs.hasChildren(parentDir)) { fs.deleteFolder(parentDir); parentDir = FileSystemPathUtil.getParentDir(parentDir); } } }