UNISTDX_FS_FILE_MODE
using mode_type = ::mode_t

Alias for system file mode type mode_t.

class sys::file_mode

File mode wrapper. A class that gives access to file mode bits via its methods.

Enumerations
  • enum mask_type

    File mode bits.

Fields
  • const mode_type type_mask

    A mask with file type bits set.

  • const mode_type perm_mask

    A mask with user, group and other bits set.

  • const mode_type mode_mask

    A mask with special, user, group and other bits set.

Methods
  • operator!=(const mode_type & rhs) const -> bool

    Comparison.

  • operator==(const mode_type & rhs) const -> bool

    Comparison.

  • operator!=(const file_mode & rhs) const -> bool

    Comparison.

  • operator==(const file_mode & rhs) const -> bool

    Comparison.

  • other() const -> mode_type

    Get other bits.

  • group() const -> mode_type

    Get group bits.

  • user() const -> mode_type

    Get user bits.

  • special() const -> mode_type

    Get special bits.

  • mode(mode_type mask) const -> mode_type

    Set file mode bits described by mask mask.

  • mode() const -> mode_type

    Get file mode.

  • operator=(mode_type rhs) -> file_mode &

    Assignment.

  • operator=(const file_mode &) -> file_mode &

    Assignment.

  • operator mode_type() const

    Automatically cast to mode_t system type.

  • operator mode_type &()

    Automatically cast to mode_t system type.

  • file_mode(const file_mode & rhs)

    Copy-constructor.

  • file_mode(mode_type rhs)

    Construct file mode from mode_t system type.

  • ~file_mode()
  • file_mode()
Friends
  • operator<<

    Print file mode bits in symbolic form. The format is similar to ls(1) command, but special bits are encoded by individual characters.

operator<<(std::ostream & out, const file_mode & rhs) -> std::ostream &

Print file mode bits in symbolic form. The format is similar to ls(1) command, but special bits are encoded by individual characters.