Zig 0.17.0-dev (Split by item)

Shortcut keys
?
Show these tips
S
Focus search field
Esc
Clear focus & close tips
U
Jump to source code
↑
Move up in search results
↓
Move down in search results
↵
Go to active search result
This is an example of documentation generated by ZigDoc, an alternative to Zig's built-in Auto Doc feature. See also examples in other modes/formats. The project being documented here (as the example) is the Zig standard library. Public Struct

Statx

Public Struct
std.os.linux.Statx
pub const Statx = extern struct

Renamed to Statx to not conflict with the statx function.

Fields

mask: STATX

Mask of bits indicating filled fields. Updated with what information the kernel returned. Callers must check this field since support varies by kernel version and filesystem.

blksize: u32

Block size for filesystem I/O.

attributes: STATX_ATTR

Extra file attribute indicators.

nlink: u32

Number of hard links.

uid: uid_t

User ID of owner.

gid: gid_t

Group ID of owner.

mode: u16

File type and mode.

__spare0: u16
ino: u64

Inode number.

size: u64

Total size in bytes.

blocks: u64

Number of 512B blocks allocated.

attributes_mask: STATX_ATTR

Mask to show what's supported in attributes.

atime: statx_timestamp

Last access file timestamp.

btime: statx_timestamp

Creation file timestamp.

ctime: statx_timestamp

Last status change file timestamp.

mtime: statx_timestamp

Last modification file timestamp.

rdev_major: u32

Major ID, if this file represents a device.

rdev_minor: u32

Minor ID, if this file represents a device.

dev_major: u32

Major ID of the device containing the filesystem where this file resides.

dev_minor: u32

Minor ID of the device containing the filesystem where this file resides.

mnt_id: u64

Mount ID

dio_mem_align: u32

Memory buffer alignment for direct I/O.

dio_offset_align: u32

File offset alignment for direct I/O.

subvol: u64

Subvolume identifier.

atomic_write_unit_min: u32

Min atomic write unit in bytes.

atomic_write_unit_max: u32

Max atomic write unit in bytes.

atomic_write_segments_max: u32

Max atomic write segment count.

dio_read_offset_align: u32

File offset alignment for direct I/O reads.

atomic_write_unit_max_opt: u32

Optimised max atomic write unit in bytes.

__spare2: [1]u32
__spare3: [8]u64

File

os/linux.zig:7974
7974
7975
7976
7977
7978
7979
7980
7981
7982
7983
7984
7985
7986
7987
7988
7989
7990
7991
7992
7993
7994
7995
7996
7997
7998
7999
8000
8001
8002
8003
8004
8005
8006
8007
8008
8009
8010
8011
8012
8013
8014
8015
8016
8017
8018
8019
8020
8021
8022
8023
8024
8025
8026
8027
8028
8029
8030
8031
8032
8033
8034
8035
8036
pub const Statx = extern struct {
    /// Mask of bits indicating filled fields. Updated with what information
    /// the kernel returned. Callers must check this field since support varies
    /// by kernel version and filesystem.
    mask: STATX,
    /// Block size for filesystem I/O.
    blksize: u32,
    /// Extra file attribute indicators.
    attributes: STATX_ATTR,
    /// Number of hard links.
    nlink: u32,
    /// User ID of owner.
    uid: uid_t,
    /// Group ID of owner.
    gid: gid_t,
    /// File type and mode.
    mode: u16,
    __spare0: u16,
    /// Inode number.
    ino: u64,
    /// Total size in bytes.
    size: u64,
    /// Number of 512B blocks allocated.
    blocks: u64,
    /// Mask to show what's supported in `attributes`.
    attributes_mask: STATX_ATTR,
    /// Last access file timestamp.
    atime: statx_timestamp,
    /// Creation file timestamp.
    btime: statx_timestamp,
    /// Last status change file timestamp.
    ctime: statx_timestamp,
    /// Last modification file timestamp.
    mtime: statx_timestamp,
    /// Major ID, if this file represents a device.
    rdev_major: u32,
    /// Minor ID, if this file represents a device.
    rdev_minor: u32,
    /// Major ID of the device containing the filesystem where this file resides.
    dev_major: u32,
    /// Minor ID of the device containing the filesystem where this file resides.
    dev_minor: u32,
    /// Mount ID
    mnt_id: u64,
    /// Memory buffer alignment for direct I/O.
    dio_mem_align: u32,
    /// File offset alignment for direct I/O.
    dio_offset_align: u32,
    /// Subvolume identifier.
    subvol: u64,
    /// Min atomic write unit in bytes.
    atomic_write_unit_min: u32,
    /// Max atomic write unit in bytes.
    atomic_write_unit_max: u32,
    /// Max atomic write segment count.
    atomic_write_segments_max: u32,
    /// File offset alignment for direct I/O reads.
    dio_read_offset_align: u32,
    /// Optimised max atomic write unit in bytes.
    atomic_write_unit_max_opt: u32,
    __spare2: [1]u32,
    __spare3: [8]u64,
}