From 9a97fe2a09bd4751be6ced7768ebe21972ee336f Mon Sep 17 00:00:00 2001 From: Sameer Vijaykar <194338+sam-vi@users.noreply.github.com> Date: Wed, 10 Jan 2024 12:12:05 +0100 Subject: [PATCH 1/7] Add an internal slot for active candidate pairs. Fixes: #188. The [[CandidatePairs]] slot in RTCIceTransport tracks candidate pairs formed by the ICE agent and surfaced to the application, and not removed via icecandidatepairremove or removeCandidatePair(). The slot is used to validate the inputs to selectCandidatePair() and removeCandidatePair(). --- index.html | 27 +++++++++++++++++++++++---- 1 file changed, 23 insertions(+), 4 deletions(-) diff --git a/index.html b/index.html index 346d0e2..dcc2690 100644 --- a/index.html +++ b/index.html @@ -747,6 +747,11 @@
+ [= list/Append =] |candidatePair| to {{RTCIceTransport/[[CandidatePairs]]}}. +
+[= Fire an event =] named @@ -877,14 +882,29 @@
- Otherwise, instruct the [= ICE agent =] to remove the candidate pair indicated by |candidatePair|.
+ Otherwise (if |accepted| is true
), run the following steps:
+ [= list/Remove =] all items that [= candidate pair match | match =] |candidatePair| from |transport|.{{RTCIceTransport/[[CandidatePairs]]}}. +
++ Instruct the [= ICE agent =] to remove the candidate pair indicated by |candidatePair|. +
+- The {{RTCIceTransport}} object is extended by adding the following internal slot: + The {{RTCIceTransport}} object is extended by adding the following internal slots:
false
.
- If |candidatePair| does not describe a candidate pair formed for [=this=] {{RTCIceTransport}} and sent in - {{RTCIceTransport/onicecandidatepairadd}}, [= exception/throw =] a {{NotFoundError}}. + If |candidatePair| does not [= candidate pair match | match =] any item in [=this=].{{RTCIceTransport/[[CandidatePairs]]}}, [= exception/throw =] a {{NotFoundError}}.
- If the {{RTCIceCandidatePair/local}} and {{RTCIceCandidatePair/remote}} attributes of candidatePair do not match a pairing of {{RTCIceCandidatePairEvent/local}} and {{RTCIceCandidatePairEvent/remote}} respectively sent in {{RTCIceTransport/onicecandidatepairadd}}, [= exception/throw =] a {{NotFoundError}}. + If |candidatePair| does not [= candidate pair match | match =] any item in [=this=].{{RTCIceTransport/[[CandidatePairs]]}}, [= exception/throw =] a {{NotFoundError}}. +
++ [= list/Remove =] all items that [= candidate pair match | match =] |candidatePair| from [=this=].{{RTCIceTransport/[[CandidatePairs]]}}.
+ [=Assert=]: |candidatePair| does not [= candidate pair match | match =] any + item in |transport|.{{RTCIceTransport/[[CandidatePairs]]}} +
+
[= list/Append =] |candidatePair| to {{RTCIceTransport/[[CandidatePairs]]}}.
From 31a97dbee434e1902ba89b25c440303e6ab590bf Mon Sep 17 00:00:00 2001
From: henbos
- [= list/Remove =] all items that [= candidate pair match | match =] |candidatePair| from |transport|.{{RTCIceTransport/[[CandidatePairs]]}}.
+ [= list/Remove =] |candidatePair| from |transport|.{{RTCIceTransport/[[CandidatePairs]]}}.
- If |candidatePair| does not [= candidate pair match | match =] any item in [=this=].{{RTCIceTransport/[[CandidatePairs]]}}, [= exception/throw =] a {{NotFoundError}}.
+ If |candidatePair| does not [= candidate pair match | match =] any item in [=this=].
+ {{RTCIceTransport/[[CandidatePairs]]}}, [= exception/throw =] a {{NotFoundError}}.
- If |candidatePair| does not [= candidate pair match | match =] any item in [=this=].{{RTCIceTransport/[[CandidatePairs]]}}, [= exception/throw =] a {{NotFoundError}}.
+ If |candidatePair| does not [= candidate pair match | match =] any item in [=this=].
+ {{RTCIceTransport/[[CandidatePairs]]}}, [= exception/throw =] a {{NotFoundError}}.
- [= list/Remove =] all items that [= candidate pair match | match =] |candidatePair| from [=this=].{{RTCIceTransport/[[CandidatePairs]]}}.
+ [= list/Remove =] the item in
+ [=this=].{{RTCIceTransport/[[CandidatePairs]]}} that
+ [= candidate pair match | matches =] |candidatePair|.
Methods
Methods
Methods