Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/windirstat/ntfs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/attribute_value/resident.rs')
-rw-r--r--src/attribute_value/resident.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/attribute_value/resident.rs b/src/attribute_value/resident.rs
index 85c4a69..65d8878 100644
--- a/src/attribute_value/resident.rs
+++ b/src/attribute_value/resident.rs
@@ -50,6 +50,11 @@ impl<'f> NtfsResidentAttributeValue<'f> {
}
}
+ /// Returns `true` if the resident attribute value contains no data.
+ pub fn is_empty(&self) -> bool {
+ self.len() == 0
+ }
+
/// Returns the total length of the resident attribute value data, in bytes.
pub fn len(&self) -> u64 {
self.data.len() as u64