Struct medea_jason::connection::Connection
source · pub struct Connection(_);
Expand description
Connection with a specific remote Member
, that is used on Rust side.
Implementations§
source§impl Connection
impl Connection
sourcepub fn new(
remote_id: MemberId,
room_recv_constraints: &Rc<RecvConstraints>
) -> Self
pub fn new( remote_id: MemberId, room_recv_constraints: &Rc<RecvConstraints> ) -> Self
Instantiates a new Connection
for the given Member
.
Based on the provided RecvConstraints
individual RecvConstraints
of this Connection
will automatically synchronize.
sourcepub fn add_receiver(&self, receiver: Rc<State>)
pub fn add_receiver(&self, receiver: Rc<State>)
Stores provided receiver::State
in this Connection
.
Updates MediaExchangeState
of the provided receiver::State
based
on the current individual RecvConstraints
of this Connection
.
sourcepub fn add_remote_track(&self, track: Track)
pub fn add_remote_track(&self, track: Track)
Invokes on_remote_track_added
callback with the provided
remote::Track
.
sourcepub fn new_handle(&self) -> ConnectionHandle
pub fn new_handle(&self) -> ConnectionHandle
Creates a new external handle to this Connection
.
sourcepub fn update_quality_score(&self, score: ConnectionQualityScore)
pub fn update_quality_score(&self, score: ConnectionQualityScore)
Updates ConnectionQualityScore
of this Connection
.
Trait Implementations§
source§impl Clone for Connection
impl Clone for Connection
source§fn clone(&self) -> Connection
fn clone(&self) -> Connection
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl !RefUnwindSafe for Connection
impl !Send for Connection
impl !Sync for Connection
impl Unpin for Connection
impl !UnwindSafe for Connection
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more