code: public static File createTempFolder(String name) throws Exception {
  
          File folder = null;
          folder = File.createTempFile(name, "", null);
          folder.delete();
          folder.mkdirs();
          folder.deleteOnExit();
          return folder;
      }
docs: This function creates a folder in the temporary-directory.<p>
  
  @param name the name of the folder
  
  @return the folder file
  
  @throws Exception if the folder can not create