Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(341)

Side by Side Diff: webrtc/examples/androidapp/src/org/appspot/apprtc/RoomParametersFetcher.java

Issue 2699533002: Revert of Add the url attribute to the IceCandidate (Java Wrapper) (Closed)
Patch Set: Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright 2014 The WebRTC Project Authors. All rights reserved. 2 * Copyright 2014 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
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
108 JSONArray messages = new JSONArray(messagesString); 108 JSONArray messages = new JSONArray(messagesString);
109 for (int i = 0; i < messages.length(); ++i) { 109 for (int i = 0; i < messages.length(); ++i) {
110 String messageString = messages.getString(i); 110 String messageString = messages.getString(i);
111 JSONObject message = new JSONObject(messageString); 111 JSONObject message = new JSONObject(messageString);
112 String messageType = message.getString("type"); 112 String messageType = message.getString("type");
113 Log.d(TAG, "GAE->C #" + i + " : " + messageString); 113 Log.d(TAG, "GAE->C #" + i + " : " + messageString);
114 if (messageType.equals("offer")) { 114 if (messageType.equals("offer")) {
115 offerSdp = new SessionDescription( 115 offerSdp = new SessionDescription(
116 SessionDescription.Type.fromCanonicalForm(messageType), message. getString("sdp")); 116 SessionDescription.Type.fromCanonicalForm(messageType), message. getString("sdp"));
117 } else if (messageType.equals("candidate")) { 117 } else if (messageType.equals("candidate")) {
118 IceCandidate candidate = new IceCandidate(message.getString("id"), 118 IceCandidate candidate = new IceCandidate(
119 message.getInt("label"), message.getString("candidate"), message .getString("url")); 119 message.getString("id"), message.getInt("label"), message.getStr ing("candidate"));
120 iceCandidates.add(candidate); 120 iceCandidates.add(candidate);
121 } else { 121 } else {
122 Log.e(TAG, "Unknown message: " + messageString); 122 Log.e(TAG, "Unknown message: " + messageString);
123 } 123 }
124 } 124 }
125 } 125 }
126 Log.d(TAG, "RoomId: " + roomId + ". ClientId: " + clientId); 126 Log.d(TAG, "RoomId: " + roomId + ". ClientId: " + clientId);
127 Log.d(TAG, "Initiator: " + initiator); 127 Log.d(TAG, "Initiator: " + initiator);
128 Log.d(TAG, "WSS url: " + wssUrl); 128 Log.d(TAG, "WSS url: " + wssUrl);
129 Log.d(TAG, "WSS POST url: " + wssPostUrl); 129 Log.d(TAG, "WSS POST url: " + wssPostUrl);
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 } 208 }
209 return ret; 209 return ret;
210 } 210 }
211 211
212 // Return the contents of an InputStream as a String. 212 // Return the contents of an InputStream as a String.
213 private static String drainStream(InputStream in) { 213 private static String drainStream(InputStream in) {
214 Scanner s = new Scanner(in).useDelimiter("\\A"); 214 Scanner s = new Scanner(in).useDelimiter("\\A");
215 return s.hasNext() ? s.next() : ""; 215 return s.hasNext() ? s.next() : "";
216 } 216 }
217 } 217 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698