pub struct PeerEvent {
pub peer: ActrId,
pub relayed: Option<bool>,
pub status: Option<WebRtcPeerStatus>,
}Expand description
Used by WebSocket and WebRTC hook callbacks to identify the remote peer
involved in the state change. For WebRTC, relayed reports whether the
selected ICE candidate pair traversed a TURN relay, and status reports
the coarse send-readiness state. For WebSocket both fields are always
None (not applicable).
Fields§
§peer: ActrIdRemote peer identity.
relayed: Option<bool>Some(true) if the WebRTC connection is TURN-relayed, Some(false) for
a direct peer-to-peer connection. Always None for WebSocket events.
status: Option<WebRtcPeerStatus>Coarse WebRTC send-readiness state. Always None for WebSocket events.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for PeerEvent
impl RefUnwindSafe for PeerEvent
impl Send for PeerEvent
impl Sync for PeerEvent
impl Unpin for PeerEvent
impl UnsafeUnpin for PeerEvent
impl UnwindSafe for PeerEvent
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