pub struct Source {
pub data: SourceData,
pub uid: u32,
pub gid: u32,
pub mode: u16,
pub modified: u32,
pub xattrs: HashMap<OsString, Vec<u8>>,
pub flags: u32,
}
Expand description
A single node to be added to the SquashFS archive.
This contains a SourceData
instance containing the actual data of the node, along with
metadata such as permissions and extended attributes. The path to the node is not part of this
object, because all information necessary to reconstruct the directory tree is contained in the
directory iterators. However, for higher-level mechanisms that abstract away details such as
inode numbers, it is helpful to associate a path with each Source
; SourceFile
is used for
this purpose.
This object is designed to be constructed by the user by setting all fields to the appropriate values.
Fields§
§data: SourceData
The type of the node and the data it contains.
uid: u32
The UID of the file.
gid: u32
The GID of the file.
mode: u16
The file mode.
modified: u32
The modification time of the file as a Unix timestamp.
xattrs: HashMap<OsString, Vec<u8>>
Extended attributes on the node. Each one must start with a valid xattr namespace (such as “user.”, and the values can be arbitrary byte strings.
flags: u32
BlockFlags
to set on the node to control how its contents are archived. Multiple flags
can be combined using |
.