Skip to main content

open

Function open 

Source
pub fn open(path: &Path) -> Result<LogicalImage, LogicalError>
Expand description

Open a logical file container (AD1 or AFF4-Logical) at path.

Sniffs the format and dispatches to the matching reader. A raw disk image or a physical AFF4 is rejected with LogicalError::NotLogical naming the format — open those with crate::container::open instead.

§Errors

LogicalError::Io on a read failure, LogicalError::NotLogical for a non-logical input, or the backend error for a corrupt/encrypted container.