Packer

Trait Packer 

Source
pub trait Packer {
    // Required methods
    fn list() -> Self::Item;
    fn get(file_name: impl AsRef<str>) -> Option<&'static [u8]>;
    fn get_str(file_name: impl AsRef<str>) -> Option<&'static str>;
}

Required Methods§

Source

fn list() -> Self::Item

Lists the files stored in the Packer.

Source

fn get(file_name: impl AsRef<str>) -> Option<&'static [u8]>

Returns the contents of the file named file_name as a &'static [u8] if it exists, None otherwise.

Source

fn get_str(file_name: impl AsRef<str>) -> Option<&'static str>

Returns the contents of the file named file_name as a &'static str if it exists and is valid UTF-8, None otherwise.

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§