Track

Trait Track 

Source
pub trait Track: Send + Sync {
    // Required methods
    fn ssrc(&self) -> u32;
    fn id(&self) -> &TrackId;
    fn config(&self) -> &TrackConfig;
    fn processor_chain(&mut self) -> &mut ProcessorChain;
    fn handshake<'life0, 'async_trait>(
        &'life0 mut self,
        offer: String,
        timeout: Option<Duration>,
    ) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn update_remote_description<'life0, 'life1, 'async_trait>(
        &'life0 mut self,
        answer: &'life1 String,
    ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn start<'life0, 'async_trait>(
        &'life0 self,
        event_sender: EventSender,
        packet_sender: TrackPacketSender,
    ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn stop<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn send_packet<'life0, 'life1, 'async_trait>(
        &'life0 self,
        packet: &'life1 AudioFrame,
    ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;

    // Provided methods
    fn insert_processor(&mut self, processor: Box<dyn Processor>) { ... }
    fn append_processor(&mut self, processor: Box<dyn Processor>) { ... }
    fn stop_graceful<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait { ... }
}

Required Methods§

Source

fn ssrc(&self) -> u32

Source

fn id(&self) -> &TrackId

Source

fn config(&self) -> &TrackConfig

Source

fn processor_chain(&mut self) -> &mut ProcessorChain

Source

fn handshake<'life0, 'async_trait>( &'life0 mut self, offer: String, timeout: Option<Duration>, ) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn update_remote_description<'life0, 'life1, 'async_trait>( &'life0 mut self, answer: &'life1 String, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn start<'life0, 'async_trait>( &'life0 self, event_sender: EventSender, packet_sender: TrackPacketSender, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn stop<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn send_packet<'life0, 'life1, 'async_trait>( &'life0 self, packet: &'life1 AudioFrame, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Provided Methods§

Source

fn insert_processor(&mut self, processor: Box<dyn Processor>)

Source

fn append_processor(&mut self, processor: Box<dyn Processor>)

Source

fn stop_graceful<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Implementors§