pub trait FileResolver {
// Required methods
fn resolve_file_data_id(&self, id: u32) -> Result<String>;
fn load_file_by_id(&self, id: u32) -> Result<Vec<u8>>;
// Provided methods
fn load_skin_by_id(&self, id: u32) -> Result<Vec<u8>> { ... }
fn load_animation_by_id(&self, id: u32) -> Result<Vec<u8>> { ... }
fn load_texture_by_id(&self, id: u32) -> Result<Vec<u8>> { ... }
fn load_physics_by_id(&self, id: &u32) -> Result<Vec<u8>> { ... }
fn load_skeleton_by_id(&self, id: &u32) -> Result<Vec<u8>> { ... }
fn load_bone_by_id(&self, id: &u32) -> Result<Vec<u8>> { ... }
}Expand description
Trait for resolving FileDataIDs to file paths and loading external files
Required Methods§
Sourcefn resolve_file_data_id(&self, id: u32) -> Result<String>
fn resolve_file_data_id(&self, id: u32) -> Result<String>
Resolve a FileDataID to a file path