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 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70
// This Source Code Form is subject to the terms of the Mozilla Public // License, v. 2.0. If a copy of the MPL was not distributed with this // file, You can obtain one at http://mozilla.org/MPL/2.0/. //! # `libblkid-rs` //! //! `libblkid_rs` provides programmatic access in Rust to the C library //! `libblkid`. //! //! ### Design //! //! The organization of the modules reflects the organization of the modules in the //! C library. The main goal of this library is to maintain the same general //! structure while taking advantage of Rust idioms. //! //! ### List of methods modified //! * `blkid_devno_to_wholedisk` - This bindings method handles the buffer internally //! and therefore does not require a buffer argument. The limit for the maximum //! size of the returned device name is 4096 bytes. Please open an issue if more //! characters are required. //! * `blkid_get_dev_size` - This method takes a `&Path` in the bindings //! and provides libblkid with the desired file descriptor. //! //! ### List of methods not included //! * `blkid_verify` - This method is not included because the struct flag //! that will notify the caller of whether it succeeded or not cannot be accessed //! from the public API. #![deny(missing_docs)] #[macro_use] mod macros; mod cache; /// Module containing all typed constants pub mod consts; #[cfg(feature = "deprecated")] mod deprecated; mod dev; mod devno; mod encode; mod err; mod partition; mod probe; mod tag; mod topology; mod utils; mod version; pub use uuid::Uuid; pub use libblkid_rs_sys::blkid_loff_t; pub use crate::{ cache::BlkidCache, consts::*, dev::{BlkidDev, BlkidDevIter}, devno::BlkidDevno, encode::{encode_string, safe_string}, err::{BlkidErr, Result}, partition::{BlkidPartition, BlkidPartlist, BlkidParttable}, probe::{ get_partition_name, get_superblock_name, is_known_fs_type, is_known_partition_type, BlkidProbe, }, tag::{parse_tag_string, BlkidTagIter}, topology::BlkidTopology, utils::{evaluate_spec, evaluate_tag, send_uevent, BlkidSectors}, version::{get_library_version, parse_version_string}, };