1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
//! # exFAT-fs
//!
//! exFAT filesystem implementation in Rust.
//!
//! ## Usage
//!
//! ```rust
//! use exfat_fs::{
//! MB,
//! format::{Exfat, FormatVolumeOptionsBuilder, Label},
//! };
//!
//! let size: u64 = 32 * MB as u64;
//! let hello_label = Label::new("Hello".to_string()).unwrap();
//!
//! let format_options = FormatVolumeOptionsBuilder::default()
//! .pack_bitmap(false)
//! .full_format(false)
//! .dev_size(size)
//! .label(hello_label)
//! .bytes_per_sector(512)
//! .build()
//! .unwrap();
//!
//! let mut formatter = Exfat::try_from(format_options).unwrap();
//!
//!
//! # let mut file = std::io::Cursor::new(vec![0u8; size as usize]);
//!
//!
//! formatter.write(&mut file).unwrap();
//! ```
//!
//! ## Limitations
//! Currently, the crate can only be used to format, but not read/write to the fs. no-std support
//! is also a work-in-progress.
/// Directory abstractions
pub
/// Disk utility functions
/// Filesystem formatting capabilities
pub const GB: u32 = 1024 * 1024 * 1024;
pub const MB: u32 = 1024 * 1024;
pub const KB: u16 = 1024;
pub const DEFAULT_BOUNDARY_ALIGNEMENT: u32 = 1024 * 1024;