30 Input/output library [input.output]

30.10 File systems [filesystems]

30.10.31 Class directory_­entry [fs.class.directory_entry]

30.10.31.3 directory_­entry observers [fs.dir.entry.obs]

Unqualified function names in the Returns: elements of the directory_­entry observers described below refer to members of the std​::​filesystem namespace.

const path& path() const noexcept; operator const path&() const noexcept;

Returns: pathobject.

bool exists() const; bool exists(error_code& ec) const noexcept;

Returns: exists(this->status()) or exists(this->status(), ec), respectively.

Throws: As specified in [fs.err.report].

bool is_block_file() const; bool is_block_file(error_code& ec) const noexcept;

Returns: is_­block_­file(this->status()) or is_­block_­file(this->status(), ec), respectively.

Throws: As specified in [fs.err.report].

bool is_character_file() const; bool is_character_file(error_code& ec) const noexcept;

Returns: is_­character_­file(this->status()) or is_­character_­file(this->status(), ec), respectively.

Throws: As specified in [fs.err.report].

bool is_directory() const; bool is_directory(error_code& ec) const noexcept;

Returns: is_­directory(this->status()) or is_­directory(this->status(), ec), respectively.

Throws: As specified in [fs.err.report].

bool is_fifo() const; bool is_fifo(error_code& ec) const noexcept;

Returns: is_­fifo(this->status()) or is_­fifo(this->status(), ec), respectively.

Throws: As specified in [fs.err.report].

bool is_other() const; bool is_other(error_code& ec) const noexcept;

Returns: is_­other(this->status()) or is_­other(this->status(), ec), respectively.

Throws: As specified in [fs.err.report].

bool is_regular_file() const; bool is_regular_file(error_code& ec) const noexcept;

Returns: is_­regular_­file(this->status()) or is_­regular_­file(this->status(), ec), respectively.

Throws: As specified in [fs.err.report].

bool is_socket() const; bool is_socket(error_code& ec) const noexcept;

Returns: is_­socket(this->status()) or is_­socket(this->status(), ec), respectively.

Throws: As specified in [fs.err.report].

bool is_symlink() const; bool is_symlink(error_code& ec) const noexcept;

Returns: is_­symlink(this->symlink_­status()) or is_­symlink(this->symlink_­status(), ec), respectively.

Throws: As specified in [fs.err.report].

uintmax_t file_size() const; uintmax_t file_size(error_code& ec) const noexcept;

Returns: If cached, the file size attribute value. Otherwise, file_­size(path()) or file_­size(path(), ec), respectively.

Throws: As specified in [fs.err.report].

uintmax_t hard_link_count() const; uintmax_t hard_link_count(error_code& ec) const noexcept;

Returns: If cached, the hard link count attribute value. Otherwise, hard_­link_­count(path()) or hard_­link_­count(path(), ec), respectively.

Throws: As specified in [fs.err.report].

file_time_type last_write_time() const; file_time_type last_write_time(error_code& ec) const noexcept;

Returns: If cached, the last write time attribute value. Otherwise, last_­write_­time(path()) or last_­write_­time(path(), ec), respectively.

Throws: As specified in [fs.err.report].

file_status status() const; file_status status(error_code& ec) const noexcept;

Returns: If cached, the status attribute value. Otherwise, status(path()) or status(path(), ec), respectively.

Throws: As specified in [fs.err.report].

file_status symlink_status() const; file_status symlink_status(error_code& ec) const noexcept;

Returns: If cached, the symlink status attribute value. Otherwise, symlink_­status(path()) or symlink_­status(path(), ec), respectively.

Throws: As specified in [fs.err.report].

bool operator==(const directory_entry& rhs) const noexcept;

Returns: pathobject == rhs.pathobject.

bool operator!=(const directory_entry& rhs) const noexcept;

Returns: pathobject != rhs.pathobject.

bool operator< (const directory_entry& rhs) const noexcept;

Returns: pathobject < rhs.pathobject.

bool operator<=(const directory_entry& rhs) const noexcept;

Returns: pathobject <= rhs.pathobject.

bool operator> (const directory_entry& rhs) const noexcept;

Returns: pathobject > rhs.pathobject.

bool operator>=(const directory_entry& rhs) const noexcept;

Returns: pathobject >= rhs.pathobject.