std::filesystem::status_known (3) - Linux Man Pages

std::filesystem::status_known: std::filesystem::status_known

NAME

std::filesystem::status_known - std::filesystem::status_known

Synopsis


Defined in header <filesystem>
bool status_known( std::filesystem::file_status s ) noexcept; (1) (since C++17)


Checks if the given file status is known, Equivalent to s.type() != file_type::none.

Parameters


s - file status to check

Return value


true if the given file status is a known file status.

Notes


Despite the name, the function checks for the file status of file_type::none (meaning an error occurred), not file_type::unknown (meaning file exists, but its type cannot be determined).

See also


status determines file attributes
symlink_status determines file attributes, checking the symlink target
               (function)
(C++17)
(C++17)
               status of the file designated by this directory entry
status symlink_status of the file designated by this directory entry
symlink_status (public member function of std::filesystem::directory_entry)