Java Utililty Methods Create Directory

List of utility methods to do Create Directory

Description

The list of methods to do Create Directory are organized into topic(s).

Method

booleanmkDir(String DirectoryName)
mk Dir
boolean bRet = false;
java.io.File file = new java.io.File(DirectoryName);
if (!file.exists() && file.mkdirs()) {
    bRet = true;
return bRet;
voidmkdir(String directoryName)
Erzeugen eines Verzeichnisses, inkl.
if (directoryName == null) {
    throw new IOException("Name des zu erzeugenden Verzeichnisses darf nicht null sein");
try {
    File file = new File(directoryName);
    file.mkdirs();
catch (SecurityException e) {
...
booleanmkdir(String dirname)
mkdir
File f = new File(dirname);
if (f.exists())
    return true;
else
    return f.mkdirs();
voidmkdir(String dirPath, boolean del)
mkdir
File dir = new File(dirPath);
if (dir.exists()) {
    if (del)
        dir.delete();
    else
        return;
if (!dir.getParentFile().exists()) {
...
Filemkdir(String dname)
mkdir
File d = new File("TESTDIR");
d.mkdir();
File f = new File(d, dname);
rm_rf(f);
f.mkdir();
return f;
voidmkdir(String folder)
mkdir
File file = new File(folder);
if (!file.exists()) {
    file.mkdir();
    System.out.println(file);
    System.out.println(file.getAbsoluteFile());
    System.out.println(file.getAbsolutePath());
intmkdir(String folderName, long lastModifiedDate)
mkdir for folderName and set the lastModifiedDate to lastModifiedDate
File file = new File(folderName);
int result = mkdir(file);
if (result != 0) {
    return (result);
if (file.setLastModified(lastModifiedDate) == false) {
    return (-2);
return (0);
booleanmkdir(String folderpath)
mkdir
boolean status = true;
File file = new File(folderpath);
if (file.exists()) {
    status = false;
} else {
    file.mkdir();
    System.out.println("Mkdir: " + folderpath);
return status;
voidmkDir(String fullPath, String directoryPath)
mk Dir
String[] dirctories = directoryPath.split("/");
if (dirctories == null || dirctories.length <= 1) {
    return;
File directory = new File(
        fullPath.substring(0, fullPath.indexOf("/" + dirctories[0] + "/") + dirctories[0].length() + 1));
if (!directory.exists()) {
    directory.mkdir();
...
booleanmkdir(String mkdirName)
mkdir
try {
    File dirFile = new File(mkdirName);
    boolean bFile = dirFile.exists();
    if (bFile) {
        return true;
    } else {
        bFile = dirFile.mkdir();
        return bFile;
...