pub trait MediaSource: Send + Sync {
// Required methods
fn len(&self) -> u64;
fn mime(&self) -> &str;
fn read_at(&self, offset: u64, buf: &mut [u8]) -> Result<usize>;
// Provided method
fn is_empty(&self) -> bool { ... }
}Expand description
Bytes a media view reads, wherever they live.
Required Methods§
Provided Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".