pub struct ConnectionHandle(/* private fields */);Expand description
External handler to a Connection with a remote Member.
Implementations§
Source§impl ConnectionHandle
impl ConnectionHandle
Sourcepub fn on_close(&self, f: DartOpaque) -> Result<(), DartOpaque>
pub fn on_close(&self, f: DartOpaque) -> Result<(), DartOpaque>
Sets a callback to be invoked once the associated Connection is
closed.
§Errors
If the core::ConnectionHandle::on_close() method errors.
Sourcepub fn on_remote_track_added(&self, f: DartOpaque) -> Result<(), DartOpaque>
pub fn on_remote_track_added(&self, f: DartOpaque) -> Result<(), DartOpaque>
Sets a callback to be invoked once a new remote::Track is added to
the associated Connection.
§Errors
If the core::ConnectionHandle::on_remote_track_added() method
errors.
Sourcepub fn on_quality_score_update(&self, f: DartOpaque) -> Result<(), DartOpaque>
pub fn on_quality_score_update(&self, f: DartOpaque) -> Result<(), DartOpaque>
Sets a callback to be invoked once a quality score of the associated
Connection is updated by a media server.
§Errors
If the core::ConnectionHandle::on_quality_score_update() method
errors.
Sourcepub fn get_remote_member_id(&self) -> Result<String, DartOpaque>
pub fn get_remote_member_id(&self) -> Result<String, DartOpaque>
Returns ID of remote Member ID of the associated Connection.
§Errors
If the core::ConnectionHandle::get_remote_member_id() method errors.
Sourcepub fn enable_remote_audio(&self) -> DartOpaque
pub fn enable_remote_audio(&self) -> DartOpaque
Enables inbound audio in the associated Connection.
Sourcepub fn disable_remote_audio(&self) -> DartOpaque
pub fn disable_remote_audio(&self) -> DartOpaque
Disables inbound audio in the associated Connection.
Sourcepub fn enable_remote_video(
&self,
source_kind: Option<MediaSourceKind>,
) -> DartOpaque
pub fn enable_remote_video( &self, source_kind: Option<MediaSourceKind>, ) -> DartOpaque
Enables inbound video in the associated Connection.
Affects only video with the provided MediaSourceKind, if any.
Sourcepub fn disable_remote_video(
&self,
source_kind: Option<MediaSourceKind>,
) -> DartOpaque
pub fn disable_remote_video( &self, source_kind: Option<MediaSourceKind>, ) -> DartOpaque
Disables inbound video in the associated Connection.
Affects only video with the provided MediaSourceKind, if any.