#[repr(C)]pub struct NamedFileProtocolInfo<Header> { /* private fields */ }
Expand description
Dynamically sized FileProtocolInfo
with a header and an UCS-2 name
All structs that can currently be queried via Get/SetInfo can be described as a (possibly empty) header followed by a variable-sized name.
Since such dynamic-sized types are a bit unpleasant to handle in Rust today, this generic struct was created to deduplicate the relevant code.
The reason why this struct covers the whole DST, as opposed to the
[Char16]
part only, is that pointers to DSTs are created in a rather
unintuitive way that is best kept centralized in one place.
Implementations
Create a FileInfo
structure
The structure will be created in-place within the provided storage
buffer. The buffer must be large enough to hold the data structure,
including a null-terminated UCS-2 version of the name
string.
The buffer must be correctly aligned. You can query the required
alignment using the alignment()
method of the Align
trait that this
struct implements.
Physical space consumed by the file on the file system volume
Time when the file was created
Time when the file was last accessed
Time when the file’s contents were last modified
Attribute bits for the file
Create a FileSystemInfo
structure
The structure will be created in-place within the provided storage
buffer. The buffer must be large enough to hold the data structure,
including a null-terminated UCS-2 version of the name
string.
The buffer must be correctly aligned. You can query the required
alignment using the alignment()
method of the Align
trait that this
struct implements.
Number of bytes managed by the file system
Number of available bytes for use by the file system
Nominal block size by which files are typically grown
Volume label
Create a FileSystemVolumeLabel
structure
The structure will be created in-place within the provided storage
buffer. The buffer must be large enough to hold the data structure,
including a null-terminated UCS-2 version of the name
string.
The buffer must be correctly aligned. You can query the required
alignment using the alignment()
method of the Align
trait that this
struct implements.
Volume label