Package java.io

Examples of java.io.File.mkdir()


            File newDir = getTargetFile(newDirName);
            if (!newDir.exists()) {
                if (verbose)
                    Debug.output("Creating " + newDir);
                if (!fakeit && overwrite)
                    newDir.mkdir();
            }
            super.handleDirectory(directory, contentNames);
        } else {
            notCopiedList.add(directory);
        }
View Full Code Here


            tmpFile = File.createTempFile("gradle_ivy_cache", "");
        } catch (IOException e) {
            throw new UncheckedIOException(e);
        }
        tmpFile.delete();
        tmpFile.mkdir();
        DeleteOnExit.addFile(tmpFile);
        return tmpFile;
    }

    public AbstractResolver createMavenRepoResolver(String name, String root, String... jarRepoUrls) {
View Full Code Here

   private void createOutputDir()
   {
      File dir = new File(OUTPUT_DIR);
      if (!dir.exists())
      {
         dir.mkdir();
      }
   } 
}
View Full Code Here

            assert (parentDir.isDirectory());
            for(String dir : dirs) {
                assert (parentDir.exists());
                File curDir = new File(parentDir, dir);
                if(!curDir.exists()) {
                    boolean mkdirSucc = curDir.mkdir();
                    assert (mkdirSucc);
                    System.err.println("Created directory.. " + curDir.getAbsolutePath());
                }
                parentDir = curDir;
            }
View Full Code Here

        }
        if(!baseDir.canWrite()) {
            throw new DbException("Could not write file. Check the permission of "
                    + baseDir.getAbsolutePath());
        }
        if(!colDir.mkdir()) {
            throw new IllegalStateException("create directory failed: " + colDir.getAbsolutePath());
        }
        coll = new DbCollection(colName, this);
        _collectionCache.put(colName, coll);
        return coll;
View Full Code Here

    protected void copyResource(File source, File destination){

        if (!(source.equals((temRep)))){    // If the archive is written  inside a resource repository, do not copy this temp rep
            if (source.isDirectory()){
                File directory = destination;
                directory.mkdir();

                File[] files =  source.listFiles();
                if (files != null){
                    for(int i=0;i < files.length; i++){
                        File f = files[i];
View Full Code Here

    Profiler profiler = new Profiler(prepName, "docs");

    File typeDir = new File(docDir, fileType);
    File prepOutputDir = new File(outputDir, prepName);
    if (!prepOutputDir.exists()) {
      if (!prepOutputDir.mkdir()) {
        mLog.error("Could not create output dir: " + prepOutputDir.getAbsolutePath());
        System.exit(1);
      }
    }
View Full Code Here

    envConfig.setTransactional(resumable);
    envConfig.setLocking(resumable);

    File envHome = new File(storageFolder + "/frontier");
    if (!envHome.exists()) {
      envHome.mkdir();
    }
    if (!resumable) {
      IO.deleteFolderContents(envHome);
    }
View Full Code Here

    for (int i = 0; i < indexFiles.length; i++) {
      String fileName = indexFiles[i].getName();
      File targetFile = new File(toDir, fileName);
      if (indexFiles[i].isDirectory()) {
        if (copySubDirs) {
          targetFile.mkdir();
          copyDirectory(indexFiles[i], targetFile, copySubDirs, excludeExtension);
        }
      } else if ((excludeExtension == null) || (!fileName.endsWith(excludeExtension))) {
        RegainToolkit.copyFile(indexFiles[i], targetFile);
      }
View Full Code Here

        }
        File tmp = null;
        try {
            tmp = File.createTempFile("tmp", ".wsdl");
            tmp.delete();
            tmp.mkdir();
        } catch (IOException ex) {
            LOG.log(Level.SEVERE, "WSDL_GENERATION_TMP_DIR_MSG", ex);
            return null;
        }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.