Java Root Directory Get getRootDir()

Here you can find the source of getRootDir()

Description

get Root Dir

License

Apache License

Declaration

public static File getRootDir() 

Method Source Code


//package com.java2s;
//License from project: Apache License 

import java.io.File;

public class Main {

    public static File getRootDir() {
        String rootDir = System.getProperty("user.home", ".");
        File rootFile = new File(rootDir, ".autotest");
        if (!rootFile.isDirectory()) {
            rootFile.mkdirs();/*from w ww.j  a v a2s  .  c  om*/
        }

        return rootFile;
    }
}

Related

  1. getRoot(final String path)
  2. getRoot(String path)
  3. getRootDir()
  4. getRootDir()
  5. getRootDir()
  6. getRootDir()
  7. getRootDir()
  8. getRootDir()
  9. getRootDirectory()