Skip to main content

Information2

Struct Information2 

Source
pub struct Information2 {
Show 19 fields pub last_fixup_time: Timedate, pub database_quota_limit: u32, pub database_quota_warn_threshold: u32, pub unknown_time1: Timedate, pub unknown_time2: Timedate, pub object_store_replica_identifier: Timedate, pub superblocks: [SuperblockSlot; 4], pub maximum_extension_granularity: u32, pub summary_bucket_granularity: u16, pub non_summary_bucket_granularity: u16, pub minimum_summary_bucket_size: u32, pub minimum_non_summary_bucket_size: u32, pub maximum_summary_bucket_size: u32, pub maximum_non_summary_bucket_size: u32, pub non_summary_append_size: u16, pub non_summary_append_factor: u16, pub summary_bucket_fill_factor: u16, pub non_summary_bucket_fill_factor: u16, pub bdbs: [BdbSlot; 2],
}
Expand description

Parsed nsfdb_database_information2_t.

Fields§

§last_fixup_time: Timedate

Most recent fix-up (compact/recovery) timestamp.

§database_quota_limit: u32

Per-database quota limit. Operator-defined; zero means unlimited.

§database_quota_warn_threshold: u32

Per-database quota warn threshold.

§unknown_time1: Timedate

First of two undocumented TIMEDATEs in this block.

§unknown_time2: Timedate

Second of two undocumented TIMEDATEs in this block.

§object_store_replica_identifier: Timedate

Object store replica identifier (TIMEDATE-shaped opaque).

§superblocks: [SuperblockSlot; 4]

Four superblock copies. Pick the freshest via the crate::superblock helpers.

§maximum_extension_granularity: u32

Maximum allowed extension granularity for file growth.

§summary_bucket_granularity: u16

Allocation granularity for summary buckets.

§non_summary_bucket_granularity: u16

Allocation granularity for non-summary buckets.

§minimum_summary_bucket_size: u32

Lower bound on summary-bucket size.

§minimum_non_summary_bucket_size: u32

Lower bound on non-summary-bucket size.

§maximum_summary_bucket_size: u32

Upper bound on summary-bucket size.

§maximum_non_summary_bucket_size: u32

Upper bound on non-summary-bucket size.

§non_summary_append_size: u16

Size in bytes that non-summary appends grow by.

§non_summary_append_factor: u16

Append factor (growth multiplier for non-summary regions).

§summary_bucket_fill_factor: u16

Fill factor target for summary buckets.

§non_summary_bucket_fill_factor: u16

Fill factor target for non-summary buckets.

§bdbs: [BdbSlot; 2]

Two BDB copies (primary + write-ahead redundancy).

Implementations§

Source§

impl Information2

Source

pub fn parse(bytes: &[u8]) -> Result<Self, NsfError>

Parse Information2 from the 124 bytes starting at INFO2_FILE_OFFSET within a full-file buffer. The caller is responsible for slicing the right window; this method only checks the slice length.

Source

pub fn populated_superblock_indices(&self) -> Vec<usize>

Slot indices 0..=3 of populated superblocks (any with non-zero position or size).

Source

pub fn populated_bdb_indices(&self) -> Vec<usize>

Slot indices 0..=1 of populated BDBs.

Trait Implementations§

Source§

impl Clone for Information2

Source§

fn clone(&self) -> Information2

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

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

Performs copy-assignment from source. Read more
Source§

impl Copy for Information2

Source§

impl Debug for Information2

Source§

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

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

impl Eq for Information2

Source§

impl PartialEq for Information2

Source§

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

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · 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 StructuralPartialEq for Information2

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.