OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2013 The WebRTC project authors. All Rights Reserved. | 2 * Copyright 2013 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
11 package org.webrtc; | 11 package org.webrtc; |
12 | 12 |
13 /** | 13 /** |
14 * Representation of a single ICE Candidate, mirroring | 14 * Representation of a single ICE Candidate, mirroring |
15 * {@code IceCandidateInterface} in the C++ API. | 15 * {@code IceCandidateInterface} in the C++ API. |
16 */ | 16 */ |
17 public class IceCandidate { | 17 public class IceCandidate { |
18 public final String sdpMid; | 18 public final String sdpMid; |
19 public final int sdpMLineIndex; | 19 public final int sdpMLineIndex; |
20 public final String sdp; | 20 public final String sdp; |
| 21 public final String serverUrl; |
21 | 22 |
22 public IceCandidate(String sdpMid, int sdpMLineIndex, String sdp) { | 23 public IceCandidate(String sdpMid, int sdpMLineIndex, String sdp) { |
23 this.sdpMid = sdpMid; | 24 this.sdpMid = sdpMid; |
24 this.sdpMLineIndex = sdpMLineIndex; | 25 this.sdpMLineIndex = sdpMLineIndex; |
25 this.sdp = sdp; | 26 this.sdp = sdp; |
| 27 this.serverUrl = ""; |
| 28 } |
| 29 |
| 30 // Only be called internally from JNI. |
| 31 private IceCandidate(String sdpMid, int sdpMLineIndex, String sdp, String serv
erUrl) { |
| 32 this.sdpMid = sdpMid; |
| 33 this.sdpMLineIndex = sdpMLineIndex; |
| 34 this.sdp = sdp; |
| 35 this.serverUrl = serverUrl; |
26 } | 36 } |
27 | 37 |
28 public String toString() { | 38 public String toString() { |
29 return sdpMid + ":" + sdpMLineIndex + ":" + sdp; | 39 return sdpMid + ":" + sdpMLineIndex + ":" + sdp + ":" + serverUrl; |
30 } | 40 } |
31 } | 41 } |
OLD | NEW |