Skip to main content

Embed

Trait Embed 

Source
pub trait Embed {
    // Required method
    fn get(
        path: &str,
    ) -> impl Future<Output = Result<Embedded>> + Send + 'static;
}
Expand description

A trait used to access to binary assets in a directory.

Required Methods§

Source

fn get(path: &str) -> impl Future<Output = Result<Embedded>> + Send + 'static

Get an embedded asset by its path.

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§