package uring

  1. Overview
  2. Docs

The mask flags are used to tell the kernel which fields the statx invocation is interested in. You may wish to use Mask.check on the returned Statx.t to verify the field has actually been filled in with a sensible value first. In general, the kernel never refused 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
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 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
val check : Int64.t -> t -> bool

check mask t checks if t is set in mask.

OCaml

Innovation. Community. Security.