Struct webrtc::ice_transport::ice_gatherer::RTCIceGatherer
source · pub struct RTCIceGatherer { /* private fields */ }
Expand description
ICEGatherer gathers local host, server reflexive and relay candidates, as well as enabling the retrieval of local Interactive Connectivity Establishment (ICE) parameters which can be exchanged in signaling.
Implementations
sourceimpl RTCIceGatherer
impl RTCIceGatherer
sourcepub async fn close(&self) -> Result<()>
pub async fn close(&self) -> Result<()>
Close prunes all local candidates, and closes the ports.
sourcepub async fn get_local_parameters(&self) -> Result<RTCIceParameters>
pub async fn get_local_parameters(&self) -> Result<RTCIceParameters>
get_local_parameters returns the ICE parameters of the ICEGatherer.
sourcepub async fn get_local_candidates(&self) -> Result<Vec<RTCIceCandidate>>
pub async fn get_local_candidates(&self) -> Result<Vec<RTCIceCandidate>>
get_local_candidates returns the sequence of valid local candidates associated with the ICEGatherer.
sourcepub fn on_local_candidate(&self, f: OnLocalCandidateHdlrFn)
pub fn on_local_candidate(&self, f: OnLocalCandidateHdlrFn)
on_local_candidate sets an event handler which fires when a new local ICE candidate is available Take note that the handler is gonna be called with a nil pointer when gathering is finished.
sourcepub fn on_state_change(&self, f: OnICEGathererStateChangeHdlrFn)
pub fn on_state_change(&self, f: OnICEGathererStateChangeHdlrFn)
on_state_change sets an event handler which fires any time the ICEGatherer changes
sourcepub fn on_gathering_complete(&self, f: OnGatheringCompleteHdlrFn)
pub fn on_gathering_complete(&self, f: OnGatheringCompleteHdlrFn)
on_gathering_complete sets an event handler which fires any time the ICEGatherer changes
sourcepub fn state(&self) -> RTCIceGathererState
pub fn state(&self) -> RTCIceGathererState
State indicates the current state of the ICE gatherer.