File system entries (represented by tt(path) objects, cf. section ref(PATH) below), have attributes: permissions (e.g., the owner may modify an entry), and types (like files, directories, and soft-links). Those attributes are defined in the class tt(std::filesystem::file_status). bf(Types): hi(file_type) Defined in the tt((std::filesystem) enum class file_type). centertbl(ll)(\ tline()()\ tr(xcell(2)(std::filesystem::file_type))\ tr(tlc()(Type)tlc()(Meaning))\ tline()()\ rowtwo(not_found (= -1)) (the file system entry was not found+nl() (not considered an error)) rowtwo(none)(the file status has not yet been evaluated+nl() or an error occurred when evaluating the status) rowtwo(regular)(a regular file) rowtwo(directory)(a directory) rowtwo(symlink)(a symbolic link) rowtwo(block)(a block device) rowtwo(character)(a character device) rowtwo(fifo)( a named pipe) rowtwo(socket)(a socket file) rowtwo(unknown)(an unknown file type) tline()()\ ) bf(Permissions): hi(perms) Defined in the tt((std::filesystem) enum class perms). The enumeration's symbols were defined to make their meanings more descriptive than the constants defined in the tthi(sys/stat.h) header file, but their values are identical. The tt(enum class perms) supports all bitwise operators. centertbl(lrll)(\ tline()()\ tr(xcell(4)(std::filesystem::perms))\ tr(cell(Symbol+nbsp(2))cell(Value)cell(sys/stat.h)tlc()(Meaning))\ tline()()\ rowfour(tt(none))(tt(0000))(nbsp(3)tt(-)tt(-)tt(-)) (No permission bits were set) rowfour(tt(owner_read))(tt(0400))(tt(S_IRUSR)) (File owner has read permission) rowfour(tt(owner_write))(tt(0200))(tt(S_IWUSR)) (File owner has write permission) rowfour(tt(owner_exec))(tt(0100))(tt(S_IXUSR)) (File owner has execute/search+nl() permissions) rowfour(tt(owner_all))(tt(0700))(tt(S_IRWXU)) (File owner has read, write, and+nl() execute/search permissions) rowfour(tt(group_read))(tt(0040))(tt(S_IRGRP)) (The file's group has read permission) rowfour(tt(group_write))(tt(0020))(tt(S_IWGRP)) (The file's group has write permission) rowfour(tt(group_exec))(tt(0010))(tt(S_IXGRP)) (The file's group has execute/search+nl() permissions) rowfour(tt(group_all))(tt(0070))(tt(S_IRWXG)) (The file's group has read, write, and+nl() execute/search permissions) rowfour(tt(others_read))(tt(0004))(tt(S_IROTH)) (Other users have read permission) rowfour(tt(others_write))(tt(0002))(tt(S_IWOTH)) (Other users have write permission) rowfour(tt(others_exec))(tt(0001))(tt(S_IXOTH)) (Other users have execute/search+nl() permissions) rowfour(tt(others_all))(tt(0007))(tt(S_IRWXO)) (Other users have read, write, and nl() execute/search permissions) rowfour(tt(all))(tt(0777))(nbsp(3)tt(-)tt(-)tt(-)) (All users have read, write, and+nl() execute/search permissions) rowfour(tt(set_uid))(tt(04000))(tt(S_ISUID)) (Set user ID to file owner user ID on+nl() execution) rowfour(tt(set_gid))(tt(02000))(tt(S_ISGID)) (Set group ID to file's user group ID on+nl() execution) rowfour(tt(sticky_bit))(tt(01000))(tt(S_ISVTX)) (POSIX XSI specifies that when set on a+nl() directory only file owners may delete+nl() files even if the directory is writeable+nl() by others (used, e.g., with tt(/tmp))) rowfour(tt(mask))(tt(07777))(nbsp(3)tt(-)tt(-)tt(-)) (All valid permission bits.) tline()()\ ) bf(Perm_options): hi(perm_options) The tt((std::file_system) enum class perm_options) specifies the way file system entries are modified centertbl(ll)(\ tline()()\ tr(xcell(2)(std::filesystem::perm_options))\ tr(tlc()(Value)tlc()(Meaning))\ tline()()\ rowtwo(replace)(current permisions are replaced new permissions) rowtwo(remove)(the specified permissions are removed from the+nl() file system entry's current permissions) rowtwo(nofollow) (when the current file system entry refers+nl() to a symbolic link the permissions of the+nl() symbolic link itself are updated) tline()()\ ) bf(Constructors): itemization( itt(explicit file_status(file_type type = file_type::none, perms permissions = perms::unknown)) ) Copy and move constructors and assignment operators are avaialble; bf(Members): itemization( itht(permissions)(perms permissions() const) returns the permissions of the file system entry represented by the tt(file_status) object.nl() Refer to section ref(FREEFS) for the function tt(permissions) changing the permissions of a file system entry; COMMENT( itt(void permissions(perms newPerms [, perm_options opts] [, error_code &ec])) modifies the permissions of the file system entry to which the tt(file_status) object refers; END) itht(type)(file_type type() const) returns the type of the file system entry to which the tt(file_status) object refers; itt(void type(file_type type)) changes the type of the file system entry to which the tt(file_tatus) object refers. )