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

Side by Side Diff: webrtc/p2p/base/jseptransport.h

Issue 2608353003: Make P2PTransportChannel inherit from IceTransportInternal. (Closed)
Patch Set: Merge Created 3 years, 11 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
« no previous file with comments | « webrtc/p2p/base/icetransportinternal.h ('k') | webrtc/p2p/base/mockicetransport.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2004 The WebRTC Project Authors. All rights reserved. 2 * Copyright 2004 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 #ifndef WEBRTC_P2P_BASE_JSEPTRANSPORT_H_ 11 #ifndef WEBRTC_P2P_BASE_JSEPTRANSPORT_H_
12 #define WEBRTC_P2P_BASE_JSEPTRANSPORT_H_ 12 #define WEBRTC_P2P_BASE_JSEPTRANSPORT_H_
13 13
14 #include <map> 14 #include <map>
15 #include <memory> 15 #include <memory>
16 #include <string> 16 #include <string>
17 #include <vector> 17 #include <vector>
18 18
19 #include "webrtc/base/constructormagic.h" 19 #include "webrtc/base/constructormagic.h"
20 #include "webrtc/base/messagequeue.h"
20 #include "webrtc/base/optional.h" 21 #include "webrtc/base/optional.h"
22 #include "webrtc/base/rtccertificate.h"
23 #include "webrtc/base/sigslot.h"
24 #include "webrtc/base/sslstreamadapter.h"
21 #include "webrtc/p2p/base/candidate.h" 25 #include "webrtc/p2p/base/candidate.h"
22 #include "webrtc/p2p/base/p2pconstants.h" 26 #include "webrtc/p2p/base/p2pconstants.h"
23 #include "webrtc/p2p/base/sessiondescription.h" 27 #include "webrtc/p2p/base/sessiondescription.h"
24 #include "webrtc/p2p/base/transportinfo.h" 28 #include "webrtc/p2p/base/transportinfo.h"
25 #include "webrtc/base/messagequeue.h"
26 #include "webrtc/base/rtccertificate.h"
27 #include "webrtc/base/sigslot.h"
28 #include "webrtc/base/sslstreamadapter.h"
29 29
30 namespace cricket { 30 namespace cricket {
31 31
32 class TransportChannelImpl; 32 class TransportChannelImpl;
33 class TransportChannelImpl; 33 class TransportChannelImpl;
34 enum class IceCandidatePairState; 34 enum class IceCandidatePairState;
35 35
36 typedef std::vector<Candidate> Candidates; 36 typedef std::vector<Candidate> Candidates;
37 37
38 // TODO(deadbeef): Move all of these enums, POD types and utility methods to 38 // TODO(deadbeef): Move all of these enums, POD types and utility methods to
(...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after
315 std::string* error_desc) const; 315 std::string* error_desc) const;
316 316
317 // Negotiates the SSL role based off the offer and answer as specified by 317 // Negotiates the SSL role based off the offer and answer as specified by
318 // RFC 4145, section-4.1. Returns false if the SSL role cannot be determined 318 // RFC 4145, section-4.1. Returns false if the SSL role cannot be determined
319 // from the local description and remote description. 319 // from the local description and remote description.
320 bool NegotiateRole(ContentAction local_role, 320 bool NegotiateRole(ContentAction local_role,
321 rtc::SSLRole* ssl_role, 321 rtc::SSLRole* ssl_role,
322 std::string* error_desc) const; 322 std::string* error_desc) const;
323 323
324 private: 324 private:
325 TransportChannelImpl* GetChannel(int component);
326
327 // Negotiates the transport parameters based on the current local and remote 325 // Negotiates the transport parameters based on the current local and remote
328 // transport description, such as the ICE role to use, and whether DTLS 326 // transport description, such as the ICE role to use, and whether DTLS
329 // should be activated. 327 // should be activated.
330 // 328 //
331 // Called when an answer TransportDescription is applied. 329 // Called when an answer TransportDescription is applied.
332 bool NegotiateTransportDescription(ContentAction local_role, 330 bool NegotiateTransportDescription(ContentAction local_role,
333 std::string* error_desc); 331 std::string* error_desc);
334 332
335 // Pushes down the transport parameters from the local description, such 333 // Pushes down the transport parameters from the local description, such
336 // as the ICE ufrag and pwd. 334 // as the ICE ufrag and pwd.
(...skipping 22 matching lines...) Expand all
359 357
360 // Candidate component => DTLS channel 358 // Candidate component => DTLS channel
361 std::map<int, TransportChannelImpl*> channels_; 359 std::map<int, TransportChannelImpl*> channels_;
362 360
363 RTC_DISALLOW_COPY_AND_ASSIGN(JsepTransport); 361 RTC_DISALLOW_COPY_AND_ASSIGN(JsepTransport);
364 }; 362 };
365 363
366 } // namespace cricket 364 } // namespace cricket
367 365
368 #endif // WEBRTC_P2P_BASE_JSEPTRANSPORT_H_ 366 #endif // WEBRTC_P2P_BASE_JSEPTRANSPORT_H_
OLDNEW
« no previous file with comments | « webrtc/p2p/base/icetransportinternal.h ('k') | webrtc/p2p/base/mockicetransport.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698