MCPcopy
hub / github.com/webrtc/samples / setLocalDescription

Method setLocalDescription

test/webrtcclient.js:95–109  ·  view source on GitHub ↗
(desc)

Source from the content-addressed store, hash-verified

93
94 // resolves with non-trickle description including candidates.
95 setLocalDescription(desc) {
96 return this.driver.executeAsyncScript((desc) => {
97 const callback = arguments[arguments.length - 1];
98
99 pc.onicecandidate = (event) => {
100 console.log('candidate', event.candidate);
101 if (!event.candidate) {
102 pc.onicecandidate = null;
103 callback(pc.localDescription);
104 }
105 };
106 pc.setLocalDescription(desc)
107 .catch(callback);
108 }, desc);
109 }
110
111 // TODO: this implicitly creates video elements, is that deseriable?
112 setRemoteDescription(desc) {

Callers 15

connection.test.jsFile · 0.80
VideoPipeFunction · 0.80
initLocalOfferMethod · 0.80
initRemoteAnswerMethod · 0.80
main.jsFile · 0.80
handleOfferFunction · 0.80
gotLocalDescriptionFunction · 0.80
gotRemoteDescriptionFunction · 0.80
gotDescription1Function · 0.80
gotDescription2Function · 0.80
handleLocalDescriptionFunction · 0.80
handleRemoteAnswerFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected