Struct ruma::events::call::candidates::CallCandidatesEventContent
source · [−]pub struct CallCandidatesEventContent {
pub call_id: OwnedVoipId,
pub party_id: Option<OwnedVoipId>,
pub candidates: Vec<Candidate, Global>,
pub version: VoipVersionId,
}
events
only.Expand description
The content of an m.call.candidates
event.
This event is sent by callers after sending an invite and by the callee after answering. Its purpose is to give the other party additional ICE candidates to try using to communicate.
Fields
call_id: OwnedVoipId
A unique identifier for the call.
party_id: Option<OwnedVoipId>
unstable-msc2746
only.Required in VoIP version 1. The unique ID for this session for the duration of the call.
Must be the same as the one sent by the previous invite or answer from this session.
candidates: Vec<Candidate, Global>
A list of candidates.
With the unstable-msc2746
feature, in VoIP version 1, this list should end with a
Candidate
with an empty candidate
field when no more candidates will be sent.
version: VoipVersionId
The version of the VoIP specification this messages adheres to.
Implementations
sourceimpl CallCandidatesEventContent
impl CallCandidatesEventContent
sourcepub fn new(
call_id: OwnedVoipId,
candidates: Vec<Candidate, Global>,
version: VoipVersionId
) -> CallCandidatesEventContent
pub fn new(
call_id: OwnedVoipId,
candidates: Vec<Candidate, Global>,
version: VoipVersionId
) -> CallCandidatesEventContent
Creates a new CallCandidatesEventContent
with the given call id, candidate list and VoIP
version.
sourcepub fn version_0(
call_id: OwnedVoipId,
candidates: Vec<Candidate, Global>
) -> CallCandidatesEventContent
pub fn version_0(
call_id: OwnedVoipId,
candidates: Vec<Candidate, Global>
) -> CallCandidatesEventContent
Convenience method to create a VoIP version 0 CallCandidatesEventContent
with all the
required fields.
sourcepub fn version_1(
call_id: OwnedVoipId,
party_id: OwnedVoipId,
candidates: Vec<Candidate, Global>
) -> CallCandidatesEventContent
Available on crate feature unstable-msc2746
only.
pub fn version_1(
call_id: OwnedVoipId,
party_id: OwnedVoipId,
candidates: Vec<Candidate, Global>
) -> CallCandidatesEventContent
unstable-msc2746
only.Convenience method to create a VoIP version 1 CallCandidatesEventContent
with all the
required fields.
Trait Implementations
sourceimpl Clone for CallCandidatesEventContent
impl Clone for CallCandidatesEventContent
sourcefn clone(&self) -> CallCandidatesEventContent
fn clone(&self) -> CallCandidatesEventContent
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresourceimpl Debug for CallCandidatesEventContent
impl Debug for CallCandidatesEventContent
sourceimpl<'de> Deserialize<'de> for CallCandidatesEventContent
impl<'de> Deserialize<'de> for CallCandidatesEventContent
sourcefn deserialize<__D>(
__deserializer: __D
) -> Result<CallCandidatesEventContent, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D
) -> Result<CallCandidatesEventContent, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
sourceimpl EventContent for CallCandidatesEventContent
impl EventContent for CallCandidatesEventContent
type EventType = MessageLikeEventType
type EventType = MessageLikeEventType
sourcefn event_type(&self) -> <CallCandidatesEventContent as EventContent>::EventType
fn event_type(&self) -> <CallCandidatesEventContent as EventContent>::EventType
m.room.message
.sourceimpl From<CallCandidatesEventContent> for AnyMessageLikeEventContent
impl From<CallCandidatesEventContent> for AnyMessageLikeEventContent
sourcefn from(c: CallCandidatesEventContent) -> AnyMessageLikeEventContent
fn from(c: CallCandidatesEventContent) -> AnyMessageLikeEventContent
sourceimpl RedactContent for CallCandidatesEventContent
impl RedactContent for CallCandidatesEventContent
type Redacted = RedactedCallCandidatesEventContent
type Redacted = RedactedCallCandidatesEventContent
sourcefn redact(self, version: &RoomVersionId) -> RedactedCallCandidatesEventContent
fn redact(self, version: &RoomVersionId) -> RedactedCallCandidatesEventContent
self
into a redacted form (removing most or all fields) according to the spec. Read more