Struct rsfs::disk::FS [] [src]

pub struct FS;

An empty struct that satisfies rsfs::FS by calling std::fs functions.

Because this is an empty struct, it is inherently thread safe and copyable. The power of using rsfs comes from the ability to choose what filesystem you want to use where: your main can use a disk backed filesystem, but your tests can use a test filesystem with injected errors.

Alternatively, the in-memory filesystem could suit your needs without forcing you to use disk.

Examples

use rsfs::*;

let fs = rsfs::disk::FS;

Trait Implementations

impl Copy for FS
[src]

impl Clone for FS
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Debug for FS
[src]

Formats the value using the given formatter.

impl GenFS for FS
[src]

The DirBuilder type in the same module implementing this trait.

The DirEntry type in the same module implementing this trait.

The File type in the same module implementing this trait.

The Metadata type in the same module implementing this trait.

The OpenOptions type in the same module implementing this trait.

The Permissions type in the same module implementing this trait.

The ReadDir type in the same module implementing this trait.

Returns the canonical form of a path with all intermediate components normalized and symbolic links resolved. Read more

Copies the contents of one file to another. This function will also copy the permission bits of the original file to the destination file. Read more

Creates a new, empty directory at the provided path. Read more

Recursively creates a directory and all its parent components if they are missing. Read more

Creates a new hard link on the filesystem. Read more

Returns metadata information of the file or directory at path. Read more

Returns an iterator over entries within a directory. Read more

Reads a symbolic link, returning the entry the link points to. Read more

Removes an existing, empty directory. Read more

Removes a directory at path after removing all of its contents. Read more

Removes a file from the filesystem. Read more

Renames a file or directory at from to to, replacing to if it exists. Read more

Changes the permissions of a file or directory. Read more

Query the metadata about a file without following symlinks. Read more

Returns a new OpenOptions for a file for this filesytem. Read more

Returns a new DirBuilder for a directory for this filesystem. Read more

Opens a file in read-only mode. Read more

Opens a file in write-only mode. Read more

impl GenFSExt for FS
[src]

Creates a new symbolic link on the filesystem. Read more