static public boolean createMissingParentDirectories(File file) {
    File parent = file.getParentFile();
    if (parent == null) {
      // Parent directory not specified, therefore it's a request to
      // create nothing. Done! ;)
      return true;
    }
    // File.mkdirs() creates the parent directories only if they don't
    // already exist; and it's okay if they do.
    parent.mkdirs();
    return parent.exists();
  }
static public boolean createMissingParentDirectories(File file) {
    File parent = file.getParentFile();
    if (parent == null) {
      
      
      return true;
    }
    
    
    parent.mkdirs();
    return parent.exists();
  }
static public boolean createMissingParentDirectories ( File file ) { File parent = file . getParentFile ( ) ; if ( parent == null ) { // Parent directory not specified, therefore it's a request to // create nothing. Done! ;) return true ; } // File.mkdirs() creates the parent directories only if they don't // already exist; and it's okay if they do. parent . mkdirs ( ) ; return parent . exists ( ) ; }
Creates the parent directories of a file. If parent directories not
specified in file's path, then nothing is done and this returns
gracefully.

@param file file whose parent directories (if any) should be created
@return {@code true} if either no parents were specified, or if all
parent directories were created successfully; {@code false} otherwise
Creates the parent directories of a file . If parent directories not specified in file s path then nothing is done and this returns gracefully .