private static void delete(final Path path, final AtomicBoolean success) {
        try {
            Files.delete(path);
            if (LOGGER.isDebugEnabled()) {
                LOGGER.debug("Deleted file " + path);
            }
        } catch (final IOException e) {
            success.set(false);
            LOGGER.error("Failed to delete file " + path);
            LOGGER.trace(e.getMessage(), e);
        }
    }
@return True if path contains no files or directories.
@throws IOException if it is unable to list the contents of path
stroom-util/src/main/java/stroom/util/io/FileUtil.java