company logo

File :: makeDirectory - Create new directory

The function creates a new directory for the directory path set as file path. When the file object refers to a file, bFile has to be set to true for creating a directory for storing the file. In order to avoid exceptions, one may check the file path by calling isDirectory() .

When the path is empty or does not contain a valid path, the function throws an exception.

Implementation details

File  :: makeDirectory ( bool bFile )

The function provides required directories for the file path, i.e. directories, which do not yet exist. The path is interpreted as directory path, i.e. a directory is also created for the last name in the path.

In order to avoid creating a directory for the last name in the path, bFile has to be set to true .

  • bFile - Is location a file

    When a file location is referenced in a path, this option should be set to true and to false otherwise.