A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://timsong-cpp.github.io/cppwp/n4659/fs.op.create_directory below:

[fs.op.create_directory]

30 Input/output library [input.output] 30.10 File systems [filesystems] 30.10.34 Filesystem operation functions [fs.op.funcs] 30.10.34.7 Create directory [fs.op.create_directory]

bool create_directory(const path& p); bool create_directory(const path& p, error_code& ec) noexcept;

Effects: Establishes the postcondition by attempting to create the directory p resolves to, as if by POSIX mkdir() with a second argument of static_­cast<int>(perms​::​all). Creation failure because p resolves to an existing directory shall not be treated as an error.

Postconditions: is_­directory(p).

Returns: true if a new directory was created, otherwise false. The signature with argument ec returns false if an error occurs.

bool create_directory(const path& p, const path& existing_p); bool create_directory(const path& p, const path& existing_p, error_code& ec) noexcept;

Effects: Establishes the postcondition by attempting to create the directory p resolves to, with attributes copied from directory existing_­p. The set of attributes copied is operating system dependent. Creation failure because p resolves to an existing directory shall not be treated as an error. [Note: For POSIX-based operating systems, the attributes are those copied by native API stat(existing_­p.c_­str(), &attributes_­stat) followed by mkdir(p.c_­str(), attributes_­stat.st_­mode). For Windows-based operating systems, the attributes are those copied by native API CreateDirectoryExW(existing_­p.c_­str(), p.c_­str(), 0). end note]

Postconditions: is_­directory(p).

Returns: true if a new directory was created, otherwise false. The signature with argument ec returns false if an error occurs.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4