OLD | NEW |
| (Empty) |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef CHROME_RENDERER_P2P_IPC_NETWORK_MANAGER_H_ | |
6 #define CHROME_RENDERER_P2P_IPC_NETWORK_MANAGER_H_ | |
7 | |
8 #include <vector> | |
9 | |
10 #include "base/compiler_specific.h" | |
11 #include "third_party/libjingle/source/talk/base/network.h" | |
12 | |
13 class P2PSocketDispatcher; | |
14 | |
15 // IpcNetworkManager is a NetworkManager for libjingle that gets a | |
16 // list of network interfaces from the browser. | |
17 class IpcNetworkManager : public talk_base::NetworkManager { | |
18 public: | |
19 // Constructor doesn't take ownership of the |socket_dispatcher|. | |
20 IpcNetworkManager(P2PSocketDispatcher* socket_dispatcher); | |
21 virtual ~IpcNetworkManager(); | |
22 | |
23 protected: | |
24 // Fills the supplied list with all usable networks. | |
25 virtual bool EnumNetworks(bool include_ignored, | |
26 std::vector<talk_base::Network*>* networks) | |
27 OVERRIDE; | |
28 | |
29 P2PSocketDispatcher* socket_dispatcher_; | |
30 }; | |
31 | |
32 #endif // CHROME_RENDERER_P2P_IPC_NETWORK_MANAGER_H_ | |
OLD | NEW |