#[repr(u8)]pub enum TypeFlag {
REGTYPE = 48,
AREGTYPE = 0,
LINK = 49,
SYMTYPE = 50,
CHRTYPE = 51,
BLKTYPE = 52,
DIRTYPE = 53,
FIFOTYPE = 54,
CONTTYPE = 55,
XHDTYPE = 120,
XGLTYPE = 103,
}
Expand description
Describes the kind of payload, that follows after a
PosixHeader
. The properties of this payload are
described inside the header.
Variants§
REGTYPE = 48
Represents a regular file. In order to be compatible with older versions of tar, a typeflag value of AREGTYPE should be silently recognized as a regular file. New archives should be created using REGTYPE. Also, for backward compatibility, tar treats a regular file whose name ends with a slash as a directory.
AREGTYPE = 0
Represents a regular file. In order to be compatible with older versions of tar, a typeflag value of AREGTYPE should be silently recognized as a regular file. New archives should be created using REGTYPE. Also, for backward compatibility, tar treats a regular file whose name ends with a slash as a directory.
LINK = 49
This flag represents a file linked to another file, of any type, previously archived. Such files are identified in Unix by each file having the same device and inode number. The linked-to name is specified in the linkname field with a trailing null.
SYMTYPE = 50
This represents a symbolic link to another file. The linked-to name is specified in the linkname field with a trailing null.
CHRTYPE = 51
Represents character special files and block special files respectively. In this case the devmajor and devminor fields will contain the major and minor device numbers respectively. Operating systems may map the device specifications to their own local specification, or may ignore the entry.
BLKTYPE = 52
Represents character special files and block special files respectively. In this case the devmajor and devminor fields will contain the major and minor device numbers respectively. Operating systems may map the device specifications to their own local specification, or may ignore the entry.
DIRTYPE = 53
This flag specifies a directory or sub-directory. The directory name in the name field should end with a slash. On systems where disk allocation is performed on a directory basis, the size field will contain the maximum number of bytes (which may be rounded to the nearest disk block allocation unit) which the directory may hold. A size field of zero indicates no such limiting. Systems which do not support limiting in this manner should ignore the size field.
FIFOTYPE = 54
This specifies a FIFO special file. Note that the archiving of a FIFO file archives the existence of this file and not its contents.
CONTTYPE = 55
This specifies a contiguous file, which is the same as a normal file except that, in operating systems which support it, all its space is allocated contiguously on the disk. Operating systems which do not allow contiguous allocation should silently treat this type as a normal file.
XHDTYPE = 120
Extended header referring to the next file in the archive
XGLTYPE = 103
Global extended header