pub struct VirtualFileSystem { /* private fields */ }Expand description
Virtual File System for FTP server
Implementations§
Source§impl VirtualFileSystem
impl VirtualFileSystem
pub fn new(root: PathBuf) -> Self
pub fn add_file(&self, path: PathBuf, file: VirtualFile) -> Result<()>
pub fn get_file(&self, path: &Path) -> Option<VirtualFile>
pub fn remove_file(&self, path: &Path) -> Result<()>
pub fn list_files(&self, path: &Path) -> Vec<VirtualFile>
pub fn clear(&self) -> Result<()>
pub fn add_fixture(&self, fixture: FileFixture) -> Result<()>
pub fn load_fixtures(&self, fixtures: Vec<FileFixture>) -> Result<()>
Trait Implementations§
Source§impl Clone for VirtualFileSystem
impl Clone for VirtualFileSystem
Source§fn clone(&self) -> VirtualFileSystem
fn clone(&self) -> VirtualFileSystem
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for VirtualFileSystem
impl !RefUnwindSafe for VirtualFileSystem
impl Send for VirtualFileSystem
impl Sync for VirtualFileSystem
impl Unpin for VirtualFileSystem
impl !UnwindSafe for VirtualFileSystem
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more