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

Side by Side Diff: webrtc/p2p/client/basicportallocator.h

Issue 1359363003: Make it possible to keep the port allocator session running (Closed) Base URL: https://chromium.googlesource.com/external/webrtc@master
Patch Set: Created 5 years, 2 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 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
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
104 int component, 104 int component,
105 const std::string& ice_ufrag, 105 const std::string& ice_ufrag,
106 const std::string& ice_pwd); 106 const std::string& ice_pwd);
107 ~BasicPortAllocatorSession(); 107 ~BasicPortAllocatorSession();
108 108
109 virtual BasicPortAllocator* allocator() { return allocator_; } 109 virtual BasicPortAllocator* allocator() { return allocator_; }
110 rtc::Thread* network_thread() { return network_thread_; } 110 rtc::Thread* network_thread() { return network_thread_; }
111 rtc::PacketSocketFactory* socket_factory() { return socket_factory_; } 111 rtc::PacketSocketFactory* socket_factory() { return socket_factory_; }
112 112
113 virtual void StartGettingPorts(); 113 virtual void StartGettingPorts();
114 virtual void StopGettingPorts(); 114 virtual void StopGettingPorts(bool keep_session_running);
115 virtual bool IsGettingPorts() { return running_; } 115 virtual bool IsGettingPorts() { return running_; }
116 116
117 protected: 117 protected:
118 // Starts the process of getting the port configurations. 118 // Starts the process of getting the port configurations.
119 virtual void GetPortConfigurations(); 119 virtual void GetPortConfigurations();
120 120
121 // Adds a port configuration that is now ready. Once we have one for each 121 // Adds a port configuration that is now ready. Once we have one for each
122 // network (or a timeout occurs), we will start allocating ports. 122 // network (or a timeout occurs), we will start allocating ports.
123 virtual void ConfigReady(PortConfiguration* config); 123 virtual void ConfigReady(PortConfiguration* config);
124 124
(...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after
320 rtc::scoped_ptr<rtc::AsyncPacketSocket> udp_socket_; 320 rtc::scoped_ptr<rtc::AsyncPacketSocket> udp_socket_;
321 // There will be only one udp port per AllocationSequence. 321 // There will be only one udp port per AllocationSequence.
322 UDPPort* udp_port_; 322 UDPPort* udp_port_;
323 std::vector<TurnPort*> turn_ports_; 323 std::vector<TurnPort*> turn_ports_;
324 int phase_; 324 int phase_;
325 }; 325 };
326 326
327 } // namespace cricket 327 } // namespace cricket
328 328
329 #endif // WEBRTC_P2P_CLIENT_BASICPORTALLOCATOR_H_ 329 #endif // WEBRTC_P2P_CLIENT_BASICPORTALLOCATOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698