Trait webrtc_ice::candidate::Candidate

source ·
pub trait Candidate: Display {
Show 22 methods // Required methods fn foundation(&self) -> String; fn id(&self) -> String; fn component(&self) -> u16; fn set_component(&self, c: u16); fn last_received(&self) -> SystemTime; fn last_sent(&self) -> SystemTime; fn network_type(&self) -> NetworkType; fn address(&self) -> String; fn port(&self) -> u16; fn priority(&self) -> u32; fn related_address(&self) -> Option<CandidateRelatedAddress>; fn candidate_type(&self) -> CandidateType; fn tcp_type(&self) -> TcpType; fn marshal(&self) -> String; fn addr(&self) -> SocketAddr; fn close<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn seen(&self, outbound: bool); fn write_to<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, raw: &'life1 [u8], dst: &'life2 (dyn Candidate + Send + Sync) ) -> Pin<Box<dyn Future<Output = Result<usize, Error>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait; fn equal(&self, other: &dyn Candidate) -> bool; fn set_ip(&self, ip: &IpAddr) -> Result<(), Error>; fn get_conn(&self) -> Option<&Arc<dyn Conn + Send + Sync>>; fn get_closed_ch(&self) -> Arc<Mutex<Option<Sender<()>>>>;
}
Expand description

Candidate represents an ICE candidate

Required Methods§

source

fn foundation(&self) -> String

An arbitrary string used in the freezing algorithm to group similar candidates. It is the same for two candidates that have the same type, base IP address, protocol (UDP, TCP, etc.), and STUN or TURN server.

source

fn id(&self) -> String

A unique identifier for just this candidate Unlike the foundation this is different for each candidate.

source

fn component(&self) -> u16

A component is a piece of a data stream. An example is one for RTP, and one for RTCP

source

fn set_component(&self, c: u16)

source

fn last_received(&self) -> SystemTime

The last time this candidate received traffic

source

fn last_sent(&self) -> SystemTime

The last time this candidate sent traffic

source

fn network_type(&self) -> NetworkType

source

fn address(&self) -> String

source

fn port(&self) -> u16

source

fn priority(&self) -> u32

source

fn related_address(&self) -> Option<CandidateRelatedAddress>

A transport address related to candidate, which is useful for diagnostics and other purposes.

source

fn candidate_type(&self) -> CandidateType

source

fn tcp_type(&self) -> TcpType

source

fn marshal(&self) -> String

source

fn addr(&self) -> SocketAddr

source

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

source

fn seen(&self, outbound: bool)

source

fn write_to<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, raw: &'life1 [u8], dst: &'life2 (dyn Candidate + Send + Sync) ) -> Pin<Box<dyn Future<Output = Result<usize, Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

source

fn equal(&self, other: &dyn Candidate) -> bool

source

fn set_ip(&self, ip: &IpAddr) -> Result<(), Error>

source

fn get_conn(&self) -> Option<&Arc<dyn Conn + Send + Sync>>

source

fn get_closed_ch(&self) -> Arc<Mutex<Option<Sender<()>>>>

Implementors§