diff options
Diffstat (limited to 'files/ko/web/api/rtcpeerconnection/localdescription')
-rw-r--r-- | files/ko/web/api/rtcpeerconnection/localdescription/index.html | 64 |
1 files changed, 64 insertions, 0 deletions
diff --git a/files/ko/web/api/rtcpeerconnection/localdescription/index.html b/files/ko/web/api/rtcpeerconnection/localdescription/index.html new file mode 100644 index 0000000000..0525c9f0eb --- /dev/null +++ b/files/ko/web/api/rtcpeerconnection/localdescription/index.html @@ -0,0 +1,64 @@ +--- +title: RTCPeerConnection.localDescription +slug: Web/API/RTCPeerConnection/localDescription +translation_of: Web/API/RTCPeerConnection/localDescription +--- +<p>{{WebRTCSidebar}}{{SeeCompatTable}}</p> + +<p>읽기 속성인 <code><strong>RTCPeerConnection.localDescription</strong></code>는 연결의 로컬 엔드에 대한 세션을 설명하는 {{domxref("RTCSessionDescription")}}를 반환합니다. 아직 설정이 안되어있다면, <strong>null</strong> 입니다.</p> + +<h2 id="Syntax">Syntax</h2> + +<pre class="syntaxbox"> var <em>sessionDescription</em> = <em>peerConnection</em>.localDescription;</pre> + +<p>기본적으로 반환 값은 해당 속성이 <code>null</code>이 아닐 때에만 {{domxref("RTCPeerConnection.pendingLocalDescription")}}의 값입니다. 그렇지 않은 경우에는 {{domxref("RTCPeerConnection.currentLocalDescription")}}의 값이 반환됩니다. 이 알고리즘 및 사용하는 이유에 대한 자세한 설명은 {{SectionOnPage("/en-US/docs/Web/API/WebRTC_API/Connectivity", "Pending and current descriptions")}}를 참조하십시오.</p> + +<h2 id="예시">예시</h2> + +<p>아래의 예시에서는 <code>localDescription</code>를 확인하고, {{domxref("RTCSessionDescription")}} 객체의 타입과 sdp필드를 담고있는 경고를 띄웁니다.</p> + +<pre class="brush: js">var pc = new RTCPeerConnection(); +… +var sd = pc.localDescription; +if (sd) { + alert("Local session: type='" + + sd.type + "'; sdp description='" + + sd.sdp + "'"); +} +else { + alert("No local session yet."); +} +</pre> + +<h2 id="사양서">사양서</h2> + +<table class="standard-table"> + <thead> + <tr> + <th scope="col">사양서</th> + <th scope="col">상태</th> + <th scope="col">코멘트</th> + </tr> + </thead> + <tbody> + <tr> + <td>{{ SpecName('WebRTC 1.0', '#widl-RTCPeerConnection-localDescription', 'RTCPeerConnection.localDescription') }}</td> + <td>{{ Spec2('WebRTC 1.0') }}</td> + <td>Initial specification.</td> + </tr> + </tbody> +</table> + +<h2 id="브라우저_호환성">브라우저 호환성</h2> + + + +<p>{{Compat("api.RTCPeerConnection.localDescription")}}</p> + +<h2 id="참조">참조</h2> + +<ul> + <li>{{domxref("RTCPeerConnection.setLocalDescription()")}}, {{domxref("RTCPeerConnection.pendingLocalDescription")}}, {{domxref("RTCPeerConnection.currentLocalDescription")}}</li> + <li>{{domxref("RTCPeerConnection.setRemoteDescription()")}}, {{domxref("RTCPeerConnection.remoteDescription")}}, {{domxref("RTCPeerConnection.pendingRemoteDescription")}}, {{domxref("RTCPeerConnection.currentRemoteDescription")}}</li> + <li><a href="/en-US/docs/Web/Guide/API/WebRTC">WebRTC</a></li> +</ul> |