Struct tugger_file_manifest::File
source · [−]pub struct File { /* private fields */ }
Expand description
Represents a virtual file, with an associated path.
Implementations
sourceimpl File
impl File
sourcepub fn new(path: impl AsRef<Path>, entry: impl Into<FileEntry>) -> Self
pub fn new(path: impl AsRef<Path>, entry: impl Into<FileEntry>) -> Self
Create a new instance from a path and FileEntry
.
sourcepub fn to_memory(&self) -> Result<Self, Error>
pub fn to_memory(&self) -> Result<Self, Error>
Obtain an instance that is guaranteed to be backed by memory.
sourcepub fn path_string(&self) -> String
pub fn path_string(&self) -> String
Obtain the path to this file as a String.
Trait Implementations
impl StructuralPartialEq for File
Auto Trait Implementations
impl RefUnwindSafe for File
impl Send for File
impl Sync for File
impl Unpin for File
impl UnwindSafe for File
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more