[−][src]Struct sunrise_fs::detail::driver::DriverManager
Instance handling drivers registration and usage.
Fields
registry: Vec<Box<dyn FileSystemDriver>>
The registry of the drivers availaible.
drives: HashMap<DiskId, Arc<Mutex<Box<dyn IStorage<Error = Error>>>>>
The drives actually opened.
partitions: HashMap<DiskId, HashMap<PartitionId, Weak<Mutex<Box<dyn FileSystemOperations>>>>>
The partitions opened in drives.
ahci_interface: AhciInterfaceProxy
AHCI IPC interface.
Implementations
impl DriverManager
[src]
pub fn register_driver(&mut self, driver: Box<dyn FileSystemDriver>)
[src]
Register a new driver
pub fn add_opened_drive(
&mut self,
disk_id: DiskId,
drive: Arc<Mutex<Box<dyn IStorage<Error = Error>>>>
)
[src]
&mut self,
disk_id: DiskId,
drive: Arc<Mutex<Box<dyn IStorage<Error = Error>>>>
)
Add a new drive to the open hashmap.
pub fn init_drives(&mut self) -> LibUserResult<()>
[src]
Do the disk init using AHCI
pub fn open_disk_storage(
&mut self,
disk_id: DiskId
) -> LibUserResult<Arc<Mutex<Box<dyn IStorage<Error = Error>>>>>
[src]
&mut self,
disk_id: DiskId
) -> LibUserResult<Arc<Mutex<Box<dyn IStorage<Error = Error>>>>>
Open a AHCI disk as a IStorage.
pub fn get_disks_count(&mut self) -> u32
[src]
Get the count of disks availaible.
pub fn construct_filesystem_from_disk_partition(
&mut self,
disk_id: DiskId,
partition_id: PartitionId,
storage: PartitionStorage
) -> LibUserResult<Arc<Mutex<Box<dyn FileSystemOperations>>>>
[src]
&mut self,
disk_id: DiskId,
partition_id: PartitionId,
storage: PartitionStorage
) -> LibUserResult<Arc<Mutex<Box<dyn FileSystemOperations>>>>
Open an instance of a filesystem.
pub fn format_disk_partition(
&self,
storage: PartitionStorage,
filesytem_type: FileSystemType
) -> LibUserResult<()>
[src]
&self,
storage: PartitionStorage,
filesytem_type: FileSystemType
) -> LibUserResult<()>
Format a partition storage to a given filesystem.
Trait Implementations
impl Default for DriverManager
[src]
Auto Trait Implementations
impl !RefUnwindSafe for DriverManager
impl Send for DriverManager
impl !Sync for DriverManager
impl Unpin for DriverManager
impl !UnwindSafe for DriverManager
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> SizedIPCBuffer for T
[src]
fn size(&self) -> usize
[src]
fn is_cool(addr: usize, size: usize) -> bool
[src]
unsafe fn from_raw_parts<'a>(addr: usize, _size: usize) -> &'a T
[src]
unsafe fn from_raw_parts_mut<'a>(addr: usize, _size: usize) -> &'a mut T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,