servo_media

Trait MediaInstance

Source
pub trait MediaInstance: Send {
    // Required methods
    fn get_id(&self) -> usize;
    fn mute(&self, val: bool) -> Result<(), ()>;
    fn suspend(&self) -> Result<(), ()>;
    fn resume(&self) -> Result<(), ()>;
}
Expand description

Common functionality for all high level media instances These currently are WebAudio AudioContexts and Players.

Required Methods§

Source

fn get_id(&self) -> usize

Source

fn mute(&self, val: bool) -> Result<(), ()>

Source

fn suspend(&self) -> Result<(), ()>

Source

fn resume(&self) -> Result<(), ()>

Implementations on Foreign Types§

Source§

impl MediaInstance for AudioContext

Source§

fn get_id(&self) -> usize

Source§

fn mute(&self, val: bool) -> Result<(), ()>

Source§

fn suspend(&self) -> Result<(), ()>

Source§

fn resume(&self) -> Result<(), ()>

Implementors§