Use draft spec links

This commit is contained in:
Manish Goregaokar 2019-01-28 22:24:16 -08:00
parent 7761243100
commit b7e2e79e53
4 changed files with 18 additions and 18 deletions

View file

@ -79,22 +79,22 @@ impl RTCIceCandidate {
} }
impl RTCIceCandidateMethods for RTCIceCandidate { impl RTCIceCandidateMethods for RTCIceCandidate {
/// https://www.w3.org/TR/webrtc/#dom-rtcicecandidate-candidate /// https://w3c.github.io/webrtc-pc/#dom-rtcicecandidate-candidate
fn Candidate(&self) -> DOMString { fn Candidate(&self) -> DOMString {
self.candidate.clone() self.candidate.clone()
} }
/// https://www.w3.org/TR/webrtc/#dom-rtcicecandidate-sdpmid /// https://w3c.github.io/webrtc-pc/#dom-rtcicecandidate-sdpmid
fn GetSdpMid(&self) -> Option<DOMString> { fn GetSdpMid(&self) -> Option<DOMString> {
self.sdp_m_id.clone() self.sdp_m_id.clone()
} }
/// https://www.w3.org/TR/webrtc/#dom-rtcicecandidate-sdpmlineindex /// https://w3c.github.io/webrtc-pc/#dom-rtcicecandidate-sdpmlineindex
fn GetSdpMLineIndex(&self) -> Option<u16> { fn GetSdpMLineIndex(&self) -> Option<u16> {
self.sdp_m_line_index.clone() self.sdp_m_line_index.clone()
} }
/// https://www.w3.org/TR/webrtc/#dom-rtcicecandidate-usernamefragment /// https://w3c.github.io/webrtc-pc/#dom-rtcicecandidate-usernamefragment
fn GetUsernameFragment(&self) -> Option<DOMString> { fn GetUsernameFragment(&self) -> Option<DOMString> {
self.username_fragment.clone() self.username_fragment.clone()
} }

View file

@ -264,17 +264,17 @@ impl RTCPeerConnection {
} }
impl RTCPeerConnectionMethods for RTCPeerConnection { impl RTCPeerConnectionMethods for RTCPeerConnection {
/// https://www.w3.org/TR/webrtc/#dom-rtcpeerconnection-icecandidate /// https://w3c.github.io/webrtc-pc/#dom-rtcpeerconnection-icecandidate
event_handler!(icecandidate, GetOnicecandidate, SetOnicecandidate); event_handler!(icecandidate, GetOnicecandidate, SetOnicecandidate);
/// https://www.w3.org/TR/webrtc/#dom-rtcpeerconnection-onnegotiationneeded /// https://w3c.github.io/webrtc-pc/#dom-rtcpeerconnection-onnegotiationneeded
event_handler!( event_handler!(
negotiationneeded, negotiationneeded,
GetOnnegotiationneeded, GetOnnegotiationneeded,
SetOnnegotiationneeded SetOnnegotiationneeded
); );
/// https://www.w3.org/TR/webrtc/#dom-rtcpeerconnection-addicecandidate /// https://w3c.github.io/webrtc-pc/#dom-rtcpeerconnection-addicecandidate
fn AddIceCandidate(&self, candidate: &RTCIceCandidateInit) -> Rc<Promise> { fn AddIceCandidate(&self, candidate: &RTCIceCandidateInit) -> Rc<Promise> {
let p = Promise::new(&self.global()); let p = Promise::new(&self.global());
if candidate.sdpMid.is_none() && candidate.sdpMLineIndex.is_none() { if candidate.sdpMid.is_none() && candidate.sdpMLineIndex.is_none() {
@ -293,7 +293,7 @@ impl RTCPeerConnectionMethods for RTCPeerConnection {
} }
// XXXManishearth this should be enqueued // XXXManishearth this should be enqueued
// https://www.w3.org/TR/webrtc/#enqueue-an-operation // https://w3c.github.io/webrtc-pc/#enqueue-an-operation
self.controller self.controller
.borrow_mut() .borrow_mut()
@ -309,7 +309,7 @@ impl RTCPeerConnectionMethods for RTCPeerConnection {
p p
} }
/// https://www.w3.org/TR/webrtc/#dom-rtcpeerconnection-createoffer /// https://w3c.github.io/webrtc-pc/#dom-rtcpeerconnection-createoffer
fn CreateOffer(&self, _options: &RTCOfferOptions) -> Rc<Promise> { fn CreateOffer(&self, _options: &RTCOfferOptions) -> Rc<Promise> {
let p = Promise::new(&self.global()); let p = Promise::new(&self.global());
if self.closed.get() { if self.closed.get() {
@ -321,7 +321,7 @@ impl RTCPeerConnectionMethods for RTCPeerConnection {
p p
} }
/// https://www.w3.org/TR/webrtc/#dom-rtcpeerconnection-createoffer /// https://w3c.github.io/webrtc-pc/#dom-rtcpeerconnection-createoffer
fn CreateAnswer(&self, _options: &RTCAnswerOptions) -> Rc<Promise> { fn CreateAnswer(&self, _options: &RTCAnswerOptions) -> Rc<Promise> {
let p = Promise::new(&self.global()); let p = Promise::new(&self.global());
if self.closed.get() { if self.closed.get() {
@ -333,17 +333,17 @@ impl RTCPeerConnectionMethods for RTCPeerConnection {
p p
} }
/// https://www.w3.org/TR/webrtc/#dom-rtcpeerconnection-localdescription /// https://w3c.github.io/webrtc-pc/#dom-rtcpeerconnection-localdescription
fn GetLocalDescription(&self) -> Option<DomRoot<RTCSessionDescription>> { fn GetLocalDescription(&self) -> Option<DomRoot<RTCSessionDescription>> {
self.local_description.get() self.local_description.get()
} }
/// https://www.w3.org/TR/webrtc/#dom-rtcpeerconnection-remotedescription /// https://w3c.github.io/webrtc-pc/#dom-rtcpeerconnection-remotedescription
fn GetRemoteDescription(&self) -> Option<DomRoot<RTCSessionDescription>> { fn GetRemoteDescription(&self) -> Option<DomRoot<RTCSessionDescription>> {
self.remote_description.get() self.remote_description.get()
} }
/// https://www.w3.org/TR/webrtc/#dom-rtcpeerconnection-setlocaldescription /// https://w3c.github.io/webrtc-pc/#dom-rtcpeerconnection-setlocaldescription
fn SetLocalDescription(&self, desc: &RTCSessionDescriptionInit) -> Rc<Promise> { fn SetLocalDescription(&self, desc: &RTCSessionDescriptionInit) -> Rc<Promise> {
// XXXManishearth validate the current state // XXXManishearth validate the current state
let p = Promise::new(&self.global()); let p = Promise::new(&self.global());
@ -376,7 +376,7 @@ impl RTCPeerConnectionMethods for RTCPeerConnection {
p p
} }
/// https://www.w3.org/TR/webrtc/#dom-rtcpeerconnection-setremotedescription /// https://w3c.github.io/webrtc-pc/#dom-rtcpeerconnection-setremotedescription
fn SetRemoteDescription(&self, desc: &RTCSessionDescriptionInit) -> Rc<Promise> { fn SetRemoteDescription(&self, desc: &RTCSessionDescriptionInit) -> Rc<Promise> {
// XXXManishearth validate the current state // XXXManishearth validate the current state
let p = Promise::new(&self.global()); let p = Promise::new(&self.global());

View file

@ -75,12 +75,12 @@ impl RTCPeerConnectionIceEvent {
} }
impl RTCPeerConnectionIceEventMethods for RTCPeerConnectionIceEvent { impl RTCPeerConnectionIceEventMethods for RTCPeerConnectionIceEvent {
/// https://www.w3.org/TR/webrtc/#dom-rtcpeerconnectioniceevent-candidate /// https://w3c.github.io/webrtc-pc/#dom-rtcpeerconnectioniceevent-candidate
fn GetCandidate(&self) -> Option<DomRoot<RTCIceCandidate>> { fn GetCandidate(&self) -> Option<DomRoot<RTCIceCandidate>> {
self.candidate.as_ref().map(|x| DomRoot::from_ref(&**x)) self.candidate.as_ref().map(|x| DomRoot::from_ref(&**x))
} }
/// https://www.w3.org/TR/webrtc/#dom-rtcpeerconnectioniceevent-url /// https://w3c.github.io/webrtc-pc/#dom-rtcpeerconnectioniceevent-url
fn GetUrl(&self) -> Option<DOMString> { fn GetUrl(&self) -> Option<DOMString> {
self.url.clone() self.url.clone()
} }

View file

@ -57,12 +57,12 @@ impl RTCSessionDescription {
} }
impl RTCSessionDescriptionMethods for RTCSessionDescription { impl RTCSessionDescriptionMethods for RTCSessionDescription {
/// https://www.w3.org/TR/webrtc/#dom-rtcsessiondescription-type /// https://w3c.github.io/webrtc-pc/#dom-rtcsessiondescription-type
fn Type(&self) -> RTCSdpType { fn Type(&self) -> RTCSdpType {
self.ty self.ty
} }
/// https://www.w3.org/TR/webrtc/#dom-rtcsessiondescription-sdp /// https://w3c.github.io/webrtc-pc/#dom-rtcsessiondescription-sdp
fn Sdp(&self) -> DOMString { fn Sdp(&self) -> DOMString {
self.sdp.clone() self.sdp.clone()
} }