Examples of mkdirs()


Examples of java.io.File.mkdirs()

      StringBuffer path = new StringBuffer(_baseIndexPath);
      path.append(name);
      String index_path = path.toString();
        File rp = new File(index_path);
        if(!rp.exists())
            rp.mkdirs();
        int wc = 0;
        //waiting for the lock of indexes
        while(wc<10 && IndexReader.isLocked(index_path)){
          try {
        Thread.sleep(100);
View Full Code Here

Examples of java.io.File.mkdirs()

      else
         defaultUploadLimitMB_ = Integer.parseInt(params.getValueParam("upload.limit.size").getValue());
      uploadLocation_ = tmpDir + "/" + pinfo.getContainerName() + "/eXoUpload";
      File uploadDir = new File(uploadLocation_);
      if (!uploadDir.exists())
         uploadDir.mkdirs();
   }

   public void createUploadResource(HttpServletRequest request) throws IOException
   {
      String uploadId = request.getParameter("uploadId");
View Full Code Here

Examples of java.io.File.mkdirs()

   */
  private NamedNode storeMolecule(Molecule molecule, Resource type)
      throws IOException {
    ComponentDirectory componentDirectory = new ComponentDirectory();
    File directory = componentDirectory.getDirectory();
    if (!directory.mkdirs()) {
      throw new IOException("Failed to create directory: " + directory);
    }
    writeMetaInf(directory, componentDirectory.getNode(), type, molecule);
    writeGraph(directory, molecule);
    return componentDirectory.getNode();
View Full Code Here

Examples of java.io.File.mkdirs()

      ntCurrentlyBeingAdded.put(molecule, componentDirectory.getNode());
    }
    result = getNameOfMolecule(molecule, METAMODEL.NonTerminalMolecule);
    if (result == null) {
      File directory = componentDirectory.getDirectory();
      directory.mkdirs();
      writeMetaInf(directory, componentDirectory.getNode(),
          METAMODEL.NonTerminalMolecule, molecule);
      writeGraph(directory, molecule);
      result = componentDirectory.getNode();
      synchronized (ntCurrentlyBeingAdded) {
View Full Code Here

Examples of java.io.File.mkdirs()

        currentlyBeingAdded.put(functionallyGroundedNode,
            componentDirectory.getNode());
      }

      File directory = componentDirectory.getDirectory();
      directory.mkdirs();
      // writeMetaInf(directory, componentDirectory.getNode(),
      // METAMODEL.FunctionallyGroundedNode, functionallyGroundedNode);
      File metaInfFile = new File(directory, "meta-inf");
      Model metaInfModel = ModelFactory.createDefaultModel();
      Resource componentRes = metaInfModel
View Full Code Here

Examples of java.io.File.mkdirs()

      dir = File.createTempFile("teststore", "dir");
    } catch (IOException e) {
      throw new RuntimeException(e);
    }
    dir.delete();
    dir.mkdirs();
//new File("teststore");
//    if (dir.exists()) {
//      FSStoreTest.delDirContent(dir);
//    } else {
//      dir.mkdirs();
View Full Code Here

Examples of java.io.File.mkdirs()

          "Another instance seems to be still running, if not delete "
              + lockFile);
    }
    lockFile.deleteOnExit();
    File moleculeStoreDir = new File(storeDir, "moleculestore");
    moleculeStoreDir.mkdirs();
    fsMoleculeStore = new FSMoleculeStore(moleculeStoreDir, cache);
    setMoleculeStore(fsMoleculeStore);
    File metaStoreFile = new File(storeDir, "meta-store.nt");
    Model metaModel = ModelFactory.createModelForGraph(new NTFileGraph(
        metaStoreFile));
View Full Code Here

Examples of java.io.File.mkdirs()

    if(!baseURI.endsWith("/"))
      baseURI += "/";
    //�����洢�ϴ��ļ���Ŀ¼
    File fp = new File(diskPath);
    if(!fp.exists())
      fp.mkdirs();
  }

  /* (non-Javadoc)
   * @see com.liusoft.dlog4j.upload.UploadFileHandler#save(java.io.File)
   */
 
View Full Code Here

Examples of java.io.File.mkdirs()

    String img_path = getPortraitPath(fileName.toString());
    File img = new File(img_path);
    File img_dir = img.getParentFile();
    if(!img_dir.exists()){
      synchronized(sync_portrait_upload){
        if(!img_dir.mkdirs())
          throw new IOException("Cannot make directory: " + img_dir.getParent());
      }
    }
    //�ж�ͼ��Ĵ�С��������Ҫ���е���
    BufferedImage orig_portrait = (BufferedImage)ImageIO.read(pFile.getInputStream());
View Full Code Here

Examples of java.io.File.mkdirs()

    private static File backup(String sourcePath, String targetPath,
            String basePath, int max, String node) throws IOException {
        File root = new File(targetPath);
        if (!root.exists()) {
            root.mkdirs();
        }
        while (true) {
            File oldest = null;
            int count = 0;
            for (File f : root.listFiles()) {
View Full Code Here
TOP
Copyright © 2015 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.