/** * Sets the directory where dumpfiles are stored locally. If it does not * exist yet, this directory will be created. Dumpfiles will later be stored * in a subdirectory "dumpfiles", but this will only be created when needed. * * @param downloadDirectory * the download base directory * @throws IOException * if the existence of the directory could not be checked or if * it did not exists and could not be created either */ public void setDownloadDirectory(String downloadDirectory) throws IOException { this.downloadDirectoryManager = DirectoryManagerFactory .createDirectoryManager(downloadDirectory, false); }
/** * Creates a new {@link DirectoryManager} for the given directory. * * @param directory * the directory that the directory manager points to * @param readOnly * if false, the directory manager will attempt to create * directories when changing to a location that does not exist * @return the directory manager * @throws IOException * if there was an IO error constructing the directory manager */ public static DirectoryManager createDirectoryManager(String directory, boolean readOnly) throws IOException { return createDirectoryManager(Paths.get(directory), readOnly); }
/** * Creates a new {@link DirectoryManager} for the given directory. * * @param directory * the directory that the directory manager points to * @param readOnly * if false, the directory manager will attempt to create * directories when changing to a location that does not exist * @return the directory manager * @throws IOException * if there was an IO error constructing the directory manager */ public static DirectoryManager createDirectoryManager(String directory, boolean readOnly) throws IOException { return createDirectoryManager(Paths.get(directory), readOnly); }
.createDirectoryManager(this.dumpFilePath.getParent(), true); } catch (IOException e) { this.directoryManager = null;
.createDirectoryManager(outputDirectory, false); OutputStream out = dm.getOutputStreamForFile(Paths .get(this.clientConfiguration.getReportFileName())
DirectoryManager dm = DirectoryManagerFactory.createDirectoryManager( outputDirectory, false); OutputStream out = dm.getOutputStreamForFile(Paths.get(filePath)