pub struct NtfsIndexAllocation<'n, 'f> { /* private fields */ }
Expand description

Structure of an $INDEX_ALLOCATION attribute.

This attribute describes the sub-nodes of a B-tree. The top-level nodes are managed via NtfsIndexRoot.

NTFS uses B-trees for describing directories (as indexes of NtfsFileNames), looking up Object IDs, Reparse Points, and Security Descriptors, to just name a few.

An $INDEX_ALLOCATION attribute can be resident or non-resident.

Reference: https://flatcap.github.io/linux-ntfs/ntfs/attributes/index_allocation.html

Implementations§

source§

impl<'n, 'f> NtfsIndexAllocation<'n, 'f>

source

pub fn record_from_vcn<T>( &self, fs: &mut T, index_record_size: u32, vcn: Vcn ) -> Result<NtfsIndexRecord>where T: Read + Seek,

Returns the NtfsIndexRecord located at the given Virtual Cluster Number (VCN).

The record is fully read, fixed up, and validated.

This function is usually called on the return value of NtfsIndexEntry::subnode_vcn to move further down in the B-tree.

source

pub fn records(&self, index_record_size: u32) -> NtfsIndexRecords<'n, 'f>

Returns an iterator over all Index Records of this $INDEX_ALLOCATION attribute (cf. NtfsIndexRecord).

Each Index Record is fully read, fixed up, and validated.

Trait Implementations§

source§

impl<'n, 'f> Clone for NtfsIndexAllocation<'n, 'f>

source§

fn clone(&self) -> NtfsIndexAllocation<'n, 'f>

Returns a copy 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<'n, 'f> Debug for NtfsIndexAllocation<'n, 'f>

source§

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

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

impl<'n, 'f> NtfsStructuredValue<'n, 'f> for NtfsIndexAllocation<'n, 'f>

source§

const TY: NtfsAttributeType = NtfsAttributeType::IndexAllocation

source§

fn from_attribute_value<T>( _fs: &mut T, value: NtfsAttributeValue<'n, 'f> ) -> Result<Self>where T: Read + Seek,

Create a structured value from an arbitrary NtfsAttributeValue.

Auto Trait Implementations§

§

impl<'n, 'f> RefUnwindSafe for NtfsIndexAllocation<'n, 'f>

§

impl<'n, 'f> Send for NtfsIndexAllocation<'n, 'f>

§

impl<'n, 'f> Sync for NtfsIndexAllocation<'n, 'f>

§

impl<'n, 'f> Unpin for NtfsIndexAllocation<'n, 'f>

§

impl<'n, 'f> UnwindSafe for NtfsIndexAllocation<'n, 'f>

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

source§

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

Mutably borrows from an owned value. 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 Twhere 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 Twhere T: Clone,

§

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 Twhere U: Into<T>,

§

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 Twhere U: TryFrom<T>,

§

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.