pub trait Build<Name, Error>: Node + Sized where
    Self::DirectoryContent: IntoIterator<Item = (Name, Self)>,
    Error: Display
{ type Path: Debug + Clone; fn join(prefix: &Self::Path, name: &Name) -> Self::Path; fn write_file(
        path: &Self::Path,
        content: &Self::FileContent
    ) -> Result<(), Error>; fn create_dir(path: &Self::Path) -> Result<(), Error>; fn build(
        self,
        path: &Self::Path
    ) -> Result<(), BuildError<Self::Path, Error>> { ... } }
Expand description

Applying FileSystemTree to the filesystem.

Generic parameters:

  • Name: Identification of a child item.
  • Error: Error type used by the other functions.

Required Associated Types

Locations of the items in the filesystem.

Required Methods

Add prefix to the root of the tree.

Write content to a file.

Create a directory at root.

Provided Methods

Build the tree into the filesystem.

Implementors