file_system/fundamentals/
mod.rs

1//! Fundamental types and structures for file system operations.
2//!
3//! This module contains the core data types used throughout the file system,
4//! including paths, sizes, positions, metadata, permissions, and other essential
5//! building blocks for file system operations.
6
7mod entry;
8mod flags;
9mod identifiers;
10mod metadata;
11mod path;
12mod permission;
13mod position;
14mod size;
15mod statistics;
16mod r#type;
17
18pub use entry::*;
19pub use flags::*;
20pub use identifiers::*;
21pub use metadata::*;
22pub use path::*;
23pub use permission::*;
24pub use position::*;
25pub use size::*;
26pub use statistics::*;
27pub use r#type::*;
28
29/// Standard block size representation for file system operations.
30///
31/// This type represents a 512-byte block, which is the standard sector size
32/// for most storage devices. It's used throughout the file system for
33/// block-aligned operations and buffer management.
34///
35/// # Examples
36///
37/// ```rust
38/// # extern crate alloc;
39/// use file_system::Block_type;
40///
41/// let block = Block_type::default();
42/// assert_eq!(block.0.len(), 512);
43/// ```
44#[repr(transparent)]
45pub struct Block(pub [u8; 512]);
46
47impl Default for Block {
48    fn default() -> Self {
49        Block([0; 512])
50    }
51}