Trait ReadFileString

Source
pub trait ReadFileString {
    // Required method
    fn read_file_string<'life0, 'life1, 'async_trait>(
        &'life0 self,
        path: &'life1 Path,
    ) -> Pin<Box<dyn Future<Output = Result<String, CrateError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
}
Expand description

We add a new method to CrateHandleInterface so we can read file text from an in-memory mock or from the real filesystem. For your real code, you might implement it differently.

Required Methods§

Source

fn read_file_string<'life0, 'life1, 'async_trait>( &'life0 self, path: &'life1 Path, ) -> Pin<Box<dyn Future<Output = Result<String, CrateError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Implementors§