Module Statx.Mask

The mask flags tell the kernel which fields the statx invocation wants. The caller must verify the field has actually been filled in with a value before using it. The kernel never refuses values specified in the mask, but may choose to not set the mask in the returned buffer from statx.

include FLAGS
type t = private int

A set of flags.

val empty : t
val of_int : int -> t

of_int i is the flags whose bits are those set in i.

val to_int : t -> int

to_int t is the integer with the bits of the flags t set.

val (+) : t -> t -> t

a + b is the union of the sets.

val mem : t -> t -> bool

mem x flags is true iff x is a subset of flags.

val (=) : t -> t -> bool

a = b is true iff a and b are the same set of flags.

val type' : t

Retrieve the kind of file field, accessible afterwards via Statx.kind.

val mode : t

Retrieve the permissions field, accessible afterwards via Statx.perm.

Retrieve the number of links field, accessible afterwards via Statx.nlink.

val uid : t

Retrieve the user ID field, accessible afterwards via Statx.uid.

val gid : t

Retrieve the group ID field, accessible afterwards via Statx.gid.

val atime : t

Retrieve the last access field, accessible afterwards via atime_nsec and atime_sec.

val mtime : t

Retrieve the last modification field, accessible afterwards via mtime_nsec and mtime_sec.

val ctime : t

Retrieve the last status change field, accessible afterwards via ctime_nsec and ctime_sec.

val ino : t

Retrieve the inode number, accessible afterwards via Statx.ino.

val size : t

Retrieve the total size in bytes, accessible afterwards via Statx.size.

val blocks : t

Retrieve the number of 512B blocks allocate, accessible afterwards via Statx.blocks.

val basic_stats : t

Retrieve all of the above flags.

val btime : t

Retrieve the birthtime field, accessible afterwards via btime_nsec and btime_sec.

val mnt_id : t
  • since Linux 5.8
val dioalign : t
  • since Linux 6.1