fn read(path: &Path) -> Result<Self, Box<dyn std::error::Error>> {
        let contents = std::fs::read(path).map_err(|source| Error::LoadError { source })?;

        Ok(toml::from_slice(&contents).map_err(|source| Error::ParseError { source })?)
    }
/// Read the configuration file from the path provided.
Read the configuration file from the path provided.
Read the configuration file from the path provided .
fn read(path: &Path) -> Result<Self, Box<dyn std::error::Error>> {
        let contents = std::fs::read(path).map_err(|source| Error::LoadError { source })?;
        Ok(toml::from_slice(&contents).map_err(|source| Error::ParseError { source })?)
    }
fn read ( path : & Path ) -> Result < Self , Box < dyn std :: error :: Error > > { let contents = std :: fs :: read ( path ) . map_err ( | source | Error :: LoadError { source } ) ? ; Ok ( toml :: from_slice ( & contents ) . map_err ( | source | Error :: ParseError { source } ) ? ) }
Read the configuration file from the path provided.
Read the configuration file from the path provided .
path
&Path
path
&Path