FileAttributes

Struct FileAttributes 

Source
pub struct FileAttributes { /* private fields */ }
Expand description

Attributes of a file or directory.

They can be used in any combination unless noted in the description of the attribute’s meaning

MS-FSCC 2.6

Implementations§

Source§

impl FileAttributes

Source

pub const fn new() -> Self

Returns an instance with zero initialized data.

Source§

impl FileAttributes

Source

pub const fn into_bytes(self) -> [u8; 4]

Returns the underlying bits.

§Layout

The returned byte array is layed out in the same way as described here.

Source

pub const fn from_bytes(bytes: [u8; 4]) -> Self

Converts the given bytes directly into the bitfield struct.

Source§

impl FileAttributes

Source

pub fn readonly(&self) -> <bool as Specifier>::InOut

Returns the value of readonly. A file or directory that is read-only. For a file, applications can read the file but cannot write to it or delete it. For a directory, applications cannot delete it, but applications can create and delete files from that directory.

Source

pub fn readonly_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of readonly.

#Errors

If the returned value contains an invalid bit pattern for readonly. A file or directory that is read-only. For a file, applications can read the file but cannot write to it or delete it. For a directory, applications cannot delete it, but applications can create and delete files from that directory.

Source

pub fn with_readonly(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of readonly set to the given value.

#Panics

If the given value is out of bounds for readonly. A file or directory that is read-only. For a file, applications can read the file but cannot write to it or delete it. For a directory, applications cannot delete it, but applications can create and delete files from that directory.

Source

pub fn with_readonly_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of readonly set to the given value.

#Errors

If the given value is out of bounds for readonly. A file or directory that is read-only. For a file, applications can read the file but cannot write to it or delete it. For a directory, applications cannot delete it, but applications can create and delete files from that directory.

Source

pub fn set_readonly(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of readonly to the given value.

#Panics

If the given value is out of bounds for readonly. A file or directory that is read-only. For a file, applications can read the file but cannot write to it or delete it. For a directory, applications cannot delete it, but applications can create and delete files from that directory.

Source

pub fn set_readonly_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of readonly to the given value.

#Errors

If the given value is out of bounds for readonly. A file or directory that is read-only. For a file, applications can read the file but cannot write to it or delete it. For a directory, applications cannot delete it, but applications can create and delete files from that directory.

Source

pub fn hidden(&self) -> <bool as Specifier>::InOut

Returns the value of hidden. A file or directory that is hidden. Files and directories marked with this attribute do not appear in an ordinary directory listing.

Source

pub fn hidden_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of hidden.

#Errors

If the returned value contains an invalid bit pattern for hidden. A file or directory that is hidden. Files and directories marked with this attribute do not appear in an ordinary directory listing.

Source

pub fn with_hidden(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of hidden set to the given value.

#Panics

If the given value is out of bounds for hidden. A file or directory that is hidden. Files and directories marked with this attribute do not appear in an ordinary directory listing.

Source

pub fn with_hidden_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of hidden set to the given value.

#Errors

If the given value is out of bounds for hidden. A file or directory that is hidden. Files and directories marked with this attribute do not appear in an ordinary directory listing.

Source

pub fn set_hidden(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of hidden to the given value.

#Panics

If the given value is out of bounds for hidden. A file or directory that is hidden. Files and directories marked with this attribute do not appear in an ordinary directory listing.

Source

pub fn set_hidden_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of hidden to the given value.

#Errors

If the given value is out of bounds for hidden. A file or directory that is hidden. Files and directories marked with this attribute do not appear in an ordinary directory listing.

Source

pub fn system(&self) -> <bool as Specifier>::InOut

Returns the value of system. A file or directory that the operating system uses a part of or uses exclusively.

Source

pub fn system_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of system.

#Errors

If the returned value contains an invalid bit pattern for system. A file or directory that the operating system uses a part of or uses exclusively.

Source

pub fn with_system(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of system set to the given value.

#Panics

If the given value is out of bounds for system. A file or directory that the operating system uses a part of or uses exclusively.

Source

pub fn with_system_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of system set to the given value.

#Errors

If the given value is out of bounds for system. A file or directory that the operating system uses a part of or uses exclusively.

Source

pub fn set_system(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of system to the given value.

#Panics

If the given value is out of bounds for system. A file or directory that the operating system uses a part of or uses exclusively.

Source

pub fn set_system_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of system to the given value.

#Errors

If the given value is out of bounds for system. A file or directory that the operating system uses a part of or uses exclusively.

Source

pub fn directory(&self) -> <bool as Specifier>::InOut

Returns the value of directory. This item is a directory.

Source

pub fn directory_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of directory.

#Errors

If the returned value contains an invalid bit pattern for directory. This item is a directory.

Source

pub fn with_directory(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of directory set to the given value.

#Panics

If the given value is out of bounds for directory. This item is a directory.

Source

pub fn with_directory_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of directory set to the given value.

#Errors

If the given value is out of bounds for directory. This item is a directory.

Source

pub fn set_directory(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of directory to the given value.

#Panics

If the given value is out of bounds for directory. This item is a directory.

Source

pub fn set_directory_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of directory to the given value.

#Errors

If the given value is out of bounds for directory. This item is a directory.

Source

pub fn archive(&self) -> <bool as Specifier>::InOut

Returns the value of archive. A file or directory that requires to be archived. Applications use this attribute to mark files for backup or removal.

Source

pub fn archive_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of archive.

#Errors

If the returned value contains an invalid bit pattern for archive. A file or directory that requires to be archived. Applications use this attribute to mark files for backup or removal.

Source

pub fn with_archive(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of archive set to the given value.

#Panics

If the given value is out of bounds for archive. A file or directory that requires to be archived. Applications use this attribute to mark files for backup or removal.

Source

pub fn with_archive_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of archive set to the given value.

#Errors

If the given value is out of bounds for archive. A file or directory that requires to be archived. Applications use this attribute to mark files for backup or removal.

Source

pub fn set_archive(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of archive to the given value.

#Panics

If the given value is out of bounds for archive. A file or directory that requires to be archived. Applications use this attribute to mark files for backup or removal.

Source

pub fn set_archive_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of archive to the given value.

#Errors

If the given value is out of bounds for archive. A file or directory that requires to be archived. Applications use this attribute to mark files for backup or removal.

Source

pub fn normal(&self) -> <bool as Specifier>::InOut

Returns the value of normal. A file that does not have other attributes set. This flag is used to clear all other flags by specifying it with no other flags set. This flag MUST be ignored if other flags are set.

Source

pub fn normal_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of normal.

#Errors

If the returned value contains an invalid bit pattern for normal. A file that does not have other attributes set. This flag is used to clear all other flags by specifying it with no other flags set. This flag MUST be ignored if other flags are set.

Source

pub fn with_normal(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of normal set to the given value.

#Panics

If the given value is out of bounds for normal. A file that does not have other attributes set. This flag is used to clear all other flags by specifying it with no other flags set. This flag MUST be ignored if other flags are set.

Source

pub fn with_normal_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of normal set to the given value.

#Errors

If the given value is out of bounds for normal. A file that does not have other attributes set. This flag is used to clear all other flags by specifying it with no other flags set. This flag MUST be ignored if other flags are set.

Source

pub fn set_normal(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of normal to the given value.

#Panics

If the given value is out of bounds for normal. A file that does not have other attributes set. This flag is used to clear all other flags by specifying it with no other flags set. This flag MUST be ignored if other flags are set.

Source

pub fn set_normal_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of normal to the given value.

#Errors

If the given value is out of bounds for normal. A file that does not have other attributes set. This flag is used to clear all other flags by specifying it with no other flags set. This flag MUST be ignored if other flags are set.

Source

pub fn temporary(&self) -> <bool as Specifier>::InOut

Returns the value of temporary. A file that is being used for temporary storage. The operating system can choose to store this file’s data in memory rather than on mass storage, writing the data to mass storage only if data remains in the file when the file is closed.

Source

pub fn temporary_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of temporary.

#Errors

If the returned value contains an invalid bit pattern for temporary. A file that is being used for temporary storage. The operating system can choose to store this file’s data in memory rather than on mass storage, writing the data to mass storage only if data remains in the file when the file is closed.

Source

pub fn with_temporary(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of temporary set to the given value.

#Panics

If the given value is out of bounds for temporary. A file that is being used for temporary storage. The operating system can choose to store this file’s data in memory rather than on mass storage, writing the data to mass storage only if data remains in the file when the file is closed.

Source

pub fn with_temporary_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of temporary set to the given value.

#Errors

If the given value is out of bounds for temporary. A file that is being used for temporary storage. The operating system can choose to store this file’s data in memory rather than on mass storage, writing the data to mass storage only if data remains in the file when the file is closed.

Source

pub fn set_temporary(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of temporary to the given value.

#Panics

If the given value is out of bounds for temporary. A file that is being used for temporary storage. The operating system can choose to store this file’s data in memory rather than on mass storage, writing the data to mass storage only if data remains in the file when the file is closed.

Source

pub fn set_temporary_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of temporary to the given value.

#Errors

If the given value is out of bounds for temporary. A file that is being used for temporary storage. The operating system can choose to store this file’s data in memory rather than on mass storage, writing the data to mass storage only if data remains in the file when the file is closed.

Source

pub fn sparse_file(&self) -> <bool as Specifier>::InOut

Returns the value of sparse_file. A file that is a sparse file.

Source

pub fn sparse_file_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of sparse_file.

#Errors

If the returned value contains an invalid bit pattern for sparse_file. A file that is a sparse file.

Source

pub fn with_sparse_file(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of sparse_file set to the given value.

#Panics

If the given value is out of bounds for sparse_file. A file that is a sparse file.

Source

pub fn with_sparse_file_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of sparse_file set to the given value.

#Errors

If the given value is out of bounds for sparse_file. A file that is a sparse file.

Source

pub fn set_sparse_file(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of sparse_file to the given value.

#Panics

If the given value is out of bounds for sparse_file. A file that is a sparse file.

Source

pub fn set_sparse_file_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of sparse_file to the given value.

#Errors

If the given value is out of bounds for sparse_file. A file that is a sparse file.

Source

pub fn reparse_point(&self) -> <bool as Specifier>::InOut

Returns the value of reparse_point. A file or directory that has an associated reparse point.

Source

pub fn reparse_point_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of reparse_point.

#Errors

If the returned value contains an invalid bit pattern for reparse_point. A file or directory that has an associated reparse point.

Source

pub fn with_reparse_point(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of reparse_point set to the given value.

#Panics

If the given value is out of bounds for reparse_point. A file or directory that has an associated reparse point.

Source

pub fn with_reparse_point_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of reparse_point set to the given value.

#Errors

If the given value is out of bounds for reparse_point. A file or directory that has an associated reparse point.

Source

pub fn set_reparse_point(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of reparse_point to the given value.

#Panics

If the given value is out of bounds for reparse_point. A file or directory that has an associated reparse point.

Source

pub fn set_reparse_point_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of reparse_point to the given value.

#Errors

If the given value is out of bounds for reparse_point. A file or directory that has an associated reparse point.

Source

pub fn compressed(&self) -> <bool as Specifier>::InOut

Returns the value of compressed. A file or directory that is compressed. For a file, all of the data in the file is compressed. For a directory, compression is the default for newly created files and subdirectories.

Source

pub fn compressed_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of compressed.

#Errors

If the returned value contains an invalid bit pattern for compressed. A file or directory that is compressed. For a file, all of the data in the file is compressed. For a directory, compression is the default for newly created files and subdirectories.

Source

pub fn with_compressed(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of compressed set to the given value.

#Panics

If the given value is out of bounds for compressed. A file or directory that is compressed. For a file, all of the data in the file is compressed. For a directory, compression is the default for newly created files and subdirectories.

Source

pub fn with_compressed_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of compressed set to the given value.

#Errors

If the given value is out of bounds for compressed. A file or directory that is compressed. For a file, all of the data in the file is compressed. For a directory, compression is the default for newly created files and subdirectories.

Source

pub fn set_compressed(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of compressed to the given value.

#Panics

If the given value is out of bounds for compressed. A file or directory that is compressed. For a file, all of the data in the file is compressed. For a directory, compression is the default for newly created files and subdirectories.

Source

pub fn set_compressed_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of compressed to the given value.

#Errors

If the given value is out of bounds for compressed. A file or directory that is compressed. For a file, all of the data in the file is compressed. For a directory, compression is the default for newly created files and subdirectories.

Source

pub fn offline(&self) -> <bool as Specifier>::InOut

Returns the value of offline. The data in this file is not available immediately. This attribute indicates that the file data is physically moved to offline storage. This attribute is used by Remote Storage, which is hierarchical storage management software.

Source

pub fn offline_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of offline.

#Errors

If the returned value contains an invalid bit pattern for offline. The data in this file is not available immediately. This attribute indicates that the file data is physically moved to offline storage. This attribute is used by Remote Storage, which is hierarchical storage management software.

Source

pub fn with_offline(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of offline set to the given value.

#Panics

If the given value is out of bounds for offline. The data in this file is not available immediately. This attribute indicates that the file data is physically moved to offline storage. This attribute is used by Remote Storage, which is hierarchical storage management software.

Source

pub fn with_offline_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of offline set to the given value.

#Errors

If the given value is out of bounds for offline. The data in this file is not available immediately. This attribute indicates that the file data is physically moved to offline storage. This attribute is used by Remote Storage, which is hierarchical storage management software.

Source

pub fn set_offline(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of offline to the given value.

#Panics

If the given value is out of bounds for offline. The data in this file is not available immediately. This attribute indicates that the file data is physically moved to offline storage. This attribute is used by Remote Storage, which is hierarchical storage management software.

Source

pub fn set_offline_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of offline to the given value.

#Errors

If the given value is out of bounds for offline. The data in this file is not available immediately. This attribute indicates that the file data is physically moved to offline storage. This attribute is used by Remote Storage, which is hierarchical storage management software.

Source

pub fn not_content_indexed(&self) -> <bool as Specifier>::InOut

Returns the value of not_content_indexed. A file or directory that is not indexed by the content indexing service.

Source

pub fn not_content_indexed_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of not_content_indexed.

#Errors

If the returned value contains an invalid bit pattern for not_content_indexed. A file or directory that is not indexed by the content indexing service.

Source

pub fn with_not_content_indexed( self, new_val: <bool as Specifier>::InOut, ) -> Self

Returns a copy of the bitfield with the value of not_content_indexed set to the given value.

#Panics

If the given value is out of bounds for not_content_indexed. A file or directory that is not indexed by the content indexing service.

Source

pub fn with_not_content_indexed_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of not_content_indexed set to the given value.

#Errors

If the given value is out of bounds for not_content_indexed. A file or directory that is not indexed by the content indexing service.

Source

pub fn set_not_content_indexed(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of not_content_indexed to the given value.

#Panics

If the given value is out of bounds for not_content_indexed. A file or directory that is not indexed by the content indexing service.

Source

pub fn set_not_content_indexed_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of not_content_indexed to the given value.

#Errors

If the given value is out of bounds for not_content_indexed. A file or directory that is not indexed by the content indexing service.

Source

pub fn encrypted(&self) -> <bool as Specifier>::InOut

Returns the value of encrypted. A file or directory that is encrypted. For a file, all data streams in the file are encrypted. For a directory, encryption is the default for newly created files and subdirectories.

Source

pub fn encrypted_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of encrypted.

#Errors

If the returned value contains an invalid bit pattern for encrypted. A file or directory that is encrypted. For a file, all data streams in the file are encrypted. For a directory, encryption is the default for newly created files and subdirectories.

Source

pub fn with_encrypted(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of encrypted set to the given value.

#Panics

If the given value is out of bounds for encrypted. A file or directory that is encrypted. For a file, all data streams in the file are encrypted. For a directory, encryption is the default for newly created files and subdirectories.

Source

pub fn with_encrypted_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of encrypted set to the given value.

#Errors

If the given value is out of bounds for encrypted. A file or directory that is encrypted. For a file, all data streams in the file are encrypted. For a directory, encryption is the default for newly created files and subdirectories.

Source

pub fn set_encrypted(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of encrypted to the given value.

#Panics

If the given value is out of bounds for encrypted. A file or directory that is encrypted. For a file, all data streams in the file are encrypted. For a directory, encryption is the default for newly created files and subdirectories.

Source

pub fn set_encrypted_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of encrypted to the given value.

#Errors

If the given value is out of bounds for encrypted. A file or directory that is encrypted. For a file, all data streams in the file are encrypted. For a directory, encryption is the default for newly created files and subdirectories.

Source

pub fn integrity_stream(&self) -> <bool as Specifier>::InOut

Returns the value of integrity_stream. A file or directory that is configured with integrity support. For a file, all data streams in the file have integrity support. For a directory, integrity support is the default for newly created files and subdirectories, unless the caller specifies otherwise.

Source

pub fn integrity_stream_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of integrity_stream.

#Errors

If the returned value contains an invalid bit pattern for integrity_stream. A file or directory that is configured with integrity support. For a file, all data streams in the file have integrity support. For a directory, integrity support is the default for newly created files and subdirectories, unless the caller specifies otherwise.

Source

pub fn with_integrity_stream(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of integrity_stream set to the given value.

#Panics

If the given value is out of bounds for integrity_stream. A file or directory that is configured with integrity support. For a file, all data streams in the file have integrity support. For a directory, integrity support is the default for newly created files and subdirectories, unless the caller specifies otherwise.

Source

pub fn with_integrity_stream_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of integrity_stream set to the given value.

#Errors

If the given value is out of bounds for integrity_stream. A file or directory that is configured with integrity support. For a file, all data streams in the file have integrity support. For a directory, integrity support is the default for newly created files and subdirectories, unless the caller specifies otherwise.

Source

pub fn set_integrity_stream(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of integrity_stream to the given value.

#Panics

If the given value is out of bounds for integrity_stream. A file or directory that is configured with integrity support. For a file, all data streams in the file have integrity support. For a directory, integrity support is the default for newly created files and subdirectories, unless the caller specifies otherwise.

Source

pub fn set_integrity_stream_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of integrity_stream to the given value.

#Errors

If the given value is out of bounds for integrity_stream. A file or directory that is configured with integrity support. For a file, all data streams in the file have integrity support. For a directory, integrity support is the default for newly created files and subdirectories, unless the caller specifies otherwise.

Source

pub fn no_scrub_data(&self) -> <bool as Specifier>::InOut

Returns the value of no_scrub_data. A file or directory that is configured to be excluded from the data integrity scan. For a directory configured with FILE_ATTRIBUTE_NO_SCRUB_DATA, the default for newly created files and subdirectories is to inherit the FILE_ATTRIBUTE_NO_SCRUB_DATA attribute.

Source

pub fn no_scrub_data_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of no_scrub_data.

#Errors

If the returned value contains an invalid bit pattern for no_scrub_data. A file or directory that is configured to be excluded from the data integrity scan. For a directory configured with FILE_ATTRIBUTE_NO_SCRUB_DATA, the default for newly created files and subdirectories is to inherit the FILE_ATTRIBUTE_NO_SCRUB_DATA attribute.

Source

pub fn with_no_scrub_data(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of no_scrub_data set to the given value.

#Panics

If the given value is out of bounds for no_scrub_data. A file or directory that is configured to be excluded from the data integrity scan. For a directory configured with FILE_ATTRIBUTE_NO_SCRUB_DATA, the default for newly created files and subdirectories is to inherit the FILE_ATTRIBUTE_NO_SCRUB_DATA attribute.

Source

pub fn with_no_scrub_data_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of no_scrub_data set to the given value.

#Errors

If the given value is out of bounds for no_scrub_data. A file or directory that is configured to be excluded from the data integrity scan. For a directory configured with FILE_ATTRIBUTE_NO_SCRUB_DATA, the default for newly created files and subdirectories is to inherit the FILE_ATTRIBUTE_NO_SCRUB_DATA attribute.

Source

pub fn set_no_scrub_data(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of no_scrub_data to the given value.

#Panics

If the given value is out of bounds for no_scrub_data. A file or directory that is configured to be excluded from the data integrity scan. For a directory configured with FILE_ATTRIBUTE_NO_SCRUB_DATA, the default for newly created files and subdirectories is to inherit the FILE_ATTRIBUTE_NO_SCRUB_DATA attribute.

Source

pub fn set_no_scrub_data_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of no_scrub_data to the given value.

#Errors

If the given value is out of bounds for no_scrub_data. A file or directory that is configured to be excluded from the data integrity scan. For a directory configured with FILE_ATTRIBUTE_NO_SCRUB_DATA, the default for newly created files and subdirectories is to inherit the FILE_ATTRIBUTE_NO_SCRUB_DATA attribute.

Source

pub fn recall_on_open(&self) -> <bool as Specifier>::InOut

Returns the value of recall_on_open. This attribute appears only in directory enumeration classes. When this attribute is set, it means that the file or directory has no physical representation on the local system; the item is virtual. Opening the item will be more expensive than usual because it will cause at least some of the file or directory content to be fetched from a remote store. This attribute can only be set by kernel-mode components. This attribute is for use with hierarchical storage management software.

Source

pub fn recall_on_open_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of recall_on_open.

#Errors

If the returned value contains an invalid bit pattern for recall_on_open. This attribute appears only in directory enumeration classes. When this attribute is set, it means that the file or directory has no physical representation on the local system; the item is virtual. Opening the item will be more expensive than usual because it will cause at least some of the file or directory content to be fetched from a remote store. This attribute can only be set by kernel-mode components. This attribute is for use with hierarchical storage management software.

Source

pub fn with_recall_on_open(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of recall_on_open set to the given value.

#Panics

If the given value is out of bounds for recall_on_open. This attribute appears only in directory enumeration classes. When this attribute is set, it means that the file or directory has no physical representation on the local system; the item is virtual. Opening the item will be more expensive than usual because it will cause at least some of the file or directory content to be fetched from a remote store. This attribute can only be set by kernel-mode components. This attribute is for use with hierarchical storage management software.

Source

pub fn with_recall_on_open_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of recall_on_open set to the given value.

#Errors

If the given value is out of bounds for recall_on_open. This attribute appears only in directory enumeration classes. When this attribute is set, it means that the file or directory has no physical representation on the local system; the item is virtual. Opening the item will be more expensive than usual because it will cause at least some of the file or directory content to be fetched from a remote store. This attribute can only be set by kernel-mode components. This attribute is for use with hierarchical storage management software.

Source

pub fn set_recall_on_open(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of recall_on_open to the given value.

#Panics

If the given value is out of bounds for recall_on_open. This attribute appears only in directory enumeration classes. When this attribute is set, it means that the file or directory has no physical representation on the local system; the item is virtual. Opening the item will be more expensive than usual because it will cause at least some of the file or directory content to be fetched from a remote store. This attribute can only be set by kernel-mode components. This attribute is for use with hierarchical storage management software.

Source

pub fn set_recall_on_open_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of recall_on_open to the given value.

#Errors

If the given value is out of bounds for recall_on_open. This attribute appears only in directory enumeration classes. When this attribute is set, it means that the file or directory has no physical representation on the local system; the item is virtual. Opening the item will be more expensive than usual because it will cause at least some of the file or directory content to be fetched from a remote store. This attribute can only be set by kernel-mode components. This attribute is for use with hierarchical storage management software.

Source

pub fn pinned(&self) -> <bool as Specifier>::InOut

Returns the value of pinned. This attribute indicates user intent that the file or directory should be kept fully present locally even when not being actively accessed. This attribute is for use with hierarchical storage management software.

Source

pub fn pinned_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of pinned.

#Errors

If the returned value contains an invalid bit pattern for pinned. This attribute indicates user intent that the file or directory should be kept fully present locally even when not being actively accessed. This attribute is for use with hierarchical storage management software.

Source

pub fn with_pinned(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of pinned set to the given value.

#Panics

If the given value is out of bounds for pinned. This attribute indicates user intent that the file or directory should be kept fully present locally even when not being actively accessed. This attribute is for use with hierarchical storage management software.

Source

pub fn with_pinned_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of pinned set to the given value.

#Errors

If the given value is out of bounds for pinned. This attribute indicates user intent that the file or directory should be kept fully present locally even when not being actively accessed. This attribute is for use with hierarchical storage management software.

Source

pub fn set_pinned(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of pinned to the given value.

#Panics

If the given value is out of bounds for pinned. This attribute indicates user intent that the file or directory should be kept fully present locally even when not being actively accessed. This attribute is for use with hierarchical storage management software.

Source

pub fn set_pinned_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of pinned to the given value.

#Errors

If the given value is out of bounds for pinned. This attribute indicates user intent that the file or directory should be kept fully present locally even when not being actively accessed. This attribute is for use with hierarchical storage management software.

Source

pub fn unpinned(&self) -> <bool as Specifier>::InOut

Returns the value of unpinned. This attribute indicates that the file or directory should not be kept fully present locally except when being actively accessed. This attribute is for use with hierarchical storage management software.

Source

pub fn unpinned_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of unpinned.

#Errors

If the returned value contains an invalid bit pattern for unpinned. This attribute indicates that the file or directory should not be kept fully present locally except when being actively accessed. This attribute is for use with hierarchical storage management software.

Source

pub fn with_unpinned(self, new_val: <bool as Specifier>::InOut) -> Self

Returns a copy of the bitfield with the value of unpinned set to the given value.

#Panics

If the given value is out of bounds for unpinned. This attribute indicates that the file or directory should not be kept fully present locally except when being actively accessed. This attribute is for use with hierarchical storage management software.

Source

pub fn with_unpinned_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of unpinned set to the given value.

#Errors

If the given value is out of bounds for unpinned. This attribute indicates that the file or directory should not be kept fully present locally except when being actively accessed. This attribute is for use with hierarchical storage management software.

Source

pub fn set_unpinned(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of unpinned to the given value.

#Panics

If the given value is out of bounds for unpinned. This attribute indicates that the file or directory should not be kept fully present locally except when being actively accessed. This attribute is for use with hierarchical storage management software.

Source

pub fn set_unpinned_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of unpinned to the given value.

#Errors

If the given value is out of bounds for unpinned. This attribute indicates that the file or directory should not be kept fully present locally except when being actively accessed. This attribute is for use with hierarchical storage management software.

Source

pub fn recall_on_data_access(&self) -> <bool as Specifier>::InOut

Returns the value of recall_on_data_access. When this attribute is set, it means that the file or directory is not fully present locally. For a file this means that not all of its data is on local storage (for example, it may be sparse with some data still in remote storage). For a directory it means that some of the directory contents are being virtualized from another location. Reading the file or enumerating the directory will be more expensive than usual because it will cause at least some of the file or directory content to be fetched from a remote store. Only kernel-mode callers can set this attribute. This attribute is for use with hierarchical storage management software.

Source

pub fn recall_on_data_access_or_err( &self, ) -> Result<<bool as Specifier>::InOut, InvalidBitPattern<<bool as Specifier>::Bytes>>

Returns the value of recall_on_data_access.

#Errors

If the returned value contains an invalid bit pattern for recall_on_data_access. When this attribute is set, it means that the file or directory is not fully present locally. For a file this means that not all of its data is on local storage (for example, it may be sparse with some data still in remote storage). For a directory it means that some of the directory contents are being virtualized from another location. Reading the file or enumerating the directory will be more expensive than usual because it will cause at least some of the file or directory content to be fetched from a remote store. Only kernel-mode callers can set this attribute. This attribute is for use with hierarchical storage management software.

Source

pub fn with_recall_on_data_access( self, new_val: <bool as Specifier>::InOut, ) -> Self

Returns a copy of the bitfield with the value of recall_on_data_access set to the given value.

#Panics

If the given value is out of bounds for recall_on_data_access. When this attribute is set, it means that the file or directory is not fully present locally. For a file this means that not all of its data is on local storage (for example, it may be sparse with some data still in remote storage). For a directory it means that some of the directory contents are being virtualized from another location. Reading the file or enumerating the directory will be more expensive than usual because it will cause at least some of the file or directory content to be fetched from a remote store. Only kernel-mode callers can set this attribute. This attribute is for use with hierarchical storage management software.

Source

pub fn with_recall_on_data_access_checked( self, new_val: <bool as Specifier>::InOut, ) -> Result<Self, OutOfBounds>

Returns a copy of the bitfield with the value of recall_on_data_access set to the given value.

#Errors

If the given value is out of bounds for recall_on_data_access. When this attribute is set, it means that the file or directory is not fully present locally. For a file this means that not all of its data is on local storage (for example, it may be sparse with some data still in remote storage). For a directory it means that some of the directory contents are being virtualized from another location. Reading the file or enumerating the directory will be more expensive than usual because it will cause at least some of the file or directory content to be fetched from a remote store. Only kernel-mode callers can set this attribute. This attribute is for use with hierarchical storage management software.

Source

pub fn set_recall_on_data_access(&mut self, new_val: <bool as Specifier>::InOut)

Sets the value of recall_on_data_access to the given value.

#Panics

If the given value is out of bounds for recall_on_data_access. When this attribute is set, it means that the file or directory is not fully present locally. For a file this means that not all of its data is on local storage (for example, it may be sparse with some data still in remote storage). For a directory it means that some of the directory contents are being virtualized from another location. Reading the file or enumerating the directory will be more expensive than usual because it will cause at least some of the file or directory content to be fetched from a remote store. Only kernel-mode callers can set this attribute. This attribute is for use with hierarchical storage management software.

Source

pub fn set_recall_on_data_access_checked( &mut self, new_val: <bool as Specifier>::InOut, ) -> Result<(), OutOfBounds>

Sets the value of recall_on_data_access to the given value.

#Errors

If the given value is out of bounds for recall_on_data_access. When this attribute is set, it means that the file or directory is not fully present locally. For a file this means that not all of its data is on local storage (for example, it may be sparse with some data still in remote storage). For a directory it means that some of the directory contents are being virtualized from another location. Reading the file or enumerating the directory will be more expensive than usual because it will cause at least some of the file or directory content to be fetched from a remote store. Only kernel-mode callers can set this attribute. This attribute is for use with hierarchical storage management software.

Trait Implementations§

Source§

impl BinRead for FileAttributes

Source§

type Args<'__binrw_generated_args_lifetime> = ()

The type used for the args parameter of read_args() and read_options(). Read more
Source§

fn read_options<R: Read + Seek>( __binrw_generated_var_reader: &mut R, __binrw_generated_var_endian: Endian, __binrw_generated_var_arguments: Self::Args<'_>, ) -> BinResult<Self>

Read Self from the reader using the given Endian and arguments. Read more
Source§

fn read<R>(reader: &mut R) -> Result<Self, Error>
where R: Read + Seek, Self: ReadEndian, Self::Args<'a>: for<'a> Required,

Read Self from the reader using default arguments. Read more
Source§

fn read_be<R>(reader: &mut R) -> Result<Self, Error>
where R: Read + Seek, Self::Args<'a>: for<'a> Required,

Read Self from the reader using default arguments and assuming big-endian byte order. Read more
Source§

fn read_le<R>(reader: &mut R) -> Result<Self, Error>
where R: Read + Seek, Self::Args<'a>: for<'a> Required,

Read Self from the reader using default arguments and assuming little-endian byte order. Read more
Source§

fn read_ne<R>(reader: &mut R) -> Result<Self, Error>
where R: Read + Seek, Self::Args<'a>: for<'a> Required,

Read T from the reader assuming native-endian byte order. Read more
Source§

fn read_args<R>(reader: &mut R, args: Self::Args<'_>) -> Result<Self, Error>
where R: Read + Seek, Self: ReadEndian,

Read Self from the reader using the given arguments. Read more
Source§

fn read_be_args<R>(reader: &mut R, args: Self::Args<'_>) -> Result<Self, Error>
where R: Read + Seek,

Read Self from the reader, assuming big-endian byte order, using the given arguments. Read more
Source§

fn read_le_args<R>(reader: &mut R, args: Self::Args<'_>) -> Result<Self, Error>
where R: Read + Seek,

Read Self from the reader, assuming little-endian byte order, using the given arguments. Read more
Source§

fn read_ne_args<R>(reader: &mut R, args: Self::Args<'_>) -> Result<Self, Error>
where R: Read + Seek,

Read T from the reader, assuming native-endian byte order, using the given arguments. Read more
Source§

impl BinWrite for FileAttributes

Source§

type Args<'__binrw_generated_args_lifetime> = ()

The type used for the args parameter of write_args() and write_options(). Read more
Source§

fn write_options<W: Write + Seek>( &self, __binrw_generated_var_writer: &mut W, __binrw_generated_var_endian: Endian, __binrw_generated_var_arguments: Self::Args<'_>, ) -> BinResult<()>

Write Self to the writer using the given Endian and arguments. Read more
Source§

fn write<W>(&self, writer: &mut W) -> Result<(), Error>
where W: Write + Seek, Self: WriteEndian, Self::Args<'a>: for<'a> Required,

Write Self to the writer using default arguments. Read more
Source§

fn write_be<W>(&self, writer: &mut W) -> Result<(), Error>
where W: Write + Seek, Self::Args<'a>: for<'a> Required,

Write Self to the writer assuming big-endian byte order. Read more
Source§

fn write_le<W>(&self, writer: &mut W) -> Result<(), Error>
where W: Write + Seek, Self::Args<'a>: for<'a> Required,

Write Self to the writer assuming little-endian byte order. Read more
Source§

fn write_ne<W>(&self, writer: &mut W) -> Result<(), Error>
where W: Write + Seek, Self::Args<'a>: for<'a> Required,

Write Self to the writer assuming native-endian byte order. Read more
Source§

fn write_args<W>( &self, writer: &mut W, args: Self::Args<'_>, ) -> Result<(), Error>
where W: Write + Seek, Self: WriteEndian,

Write Self to the writer using the given arguments. Read more
Source§

fn write_be_args<W>( &self, writer: &mut W, args: Self::Args<'_>, ) -> Result<(), Error>
where W: Write + Seek,

Write Self to the writer, assuming big-endian byte order, using the given arguments. Read more
Source§

fn write_le_args<W>( &self, writer: &mut W, args: Self::Args<'_>, ) -> Result<(), Error>
where W: Write + Seek,

Write Self to the writer, assuming little-endian byte order, using the given arguments. Read more
Source§

fn write_ne_args<W>( &self, writer: &mut W, args: Self::Args<'_>, ) -> Result<(), Error>
where W: Write + Seek,

Write Self to the writer, assuming native-endian byte order, using the given arguments. Read more
Source§

impl CheckTotalSizeMultipleOf8 for FileAttributes

Source§

type Size = TotalSize<[(); 0]>

Source§

impl Clone for FileAttributes

Source§

fn clone(&self) -> FileAttributes

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for FileAttributes

Source§

fn fmt(&self, __bf_f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for FileAttributes

Source§

fn default() -> FileAttributes

Returns the “default value” for a type. Read more
Source§

impl PartialEq for FileAttributes

Source§

fn eq(&self, other: &FileAttributes) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl ReadEndian for FileAttributes

Source§

const ENDIAN: EndianKind = binrw::meta::EndianKind::None

The endianness of the type.
Source§

impl WriteEndian for FileAttributes

Source§

const ENDIAN: EndianKind = binrw::meta::EndianKind::None

The endianness of the type.
Source§

impl Copy for FileAttributes

Source§

impl Eq for FileAttributes

Source§

impl StructuralPartialEq for FileAttributes

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V