Trait GenFSExt

Source
pub trait GenFSExt {
    // Required method
    fn symlink<P: AsRef<Path>, Q: AsRef<Path>>(
        &self,
        src: P,
        dst: Q,
    ) -> Result<()>;
}
Expand description

Unix specific rsfs::GenFS extensions.

Required Methods§

Creates a new symbolic link on the filesystem.

The dst path will be a symbolic link pointing to the src path.

§Examples
use rsfs::*;
use rsfs::unix_ext::*;
use rsfs::mem::FS;
let fs = FS::new();

fs.symlink("a.txt", "b.txt")?;

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl GenFSExt for rsfs::disk::FS

Source§

impl GenFSExt for rsfs::mem::FS

Source§

impl GenFSExt for rsfs::mem::unix::FS