OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef PPAPI_CPP_NETWORK_MONITOR_H_ | 5 #ifndef PPAPI_CPP_NETWORK_MONITOR_H_ |
6 #define PPAPI_CPP_NETWORK_MONITOR_H_ | 6 #define PPAPI_CPP_NETWORK_MONITOR_H_ |
7 | 7 |
| 8 #include <stdint.h> |
| 9 |
8 #include "ppapi/cpp/instance_handle.h" | 10 #include "ppapi/cpp/instance_handle.h" |
9 #include "ppapi/cpp/resource.h" | 11 #include "ppapi/cpp/resource.h" |
10 | 12 |
11 namespace pp { | 13 namespace pp { |
12 | 14 |
13 class Instance; | 15 class Instance; |
14 class NetworkList; | 16 class NetworkList; |
15 | 17 |
16 template <typename T> class CompletionCallbackWithOutput; | 18 template <typename T> class CompletionCallbackWithOutput; |
17 | 19 |
18 class NetworkMonitor : public Resource { | 20 class NetworkMonitor : public Resource { |
19 public: | 21 public: |
20 explicit NetworkMonitor(const InstanceHandle& instance); | 22 explicit NetworkMonitor(const InstanceHandle& instance); |
21 | 23 |
22 int32_t UpdateNetworkList( | 24 int32_t UpdateNetworkList( |
23 const CompletionCallbackWithOutput<NetworkList>& callback); | 25 const CompletionCallbackWithOutput<NetworkList>& callback); |
24 | 26 |
25 // Returns true if the required interface is available. | 27 // Returns true if the required interface is available. |
26 static bool IsAvailable(); | 28 static bool IsAvailable(); |
27 }; | 29 }; |
28 | 30 |
29 } // namespace pp | 31 } // namespace pp |
30 | 32 |
31 #endif // PPAPI_CPP_NETWORK_MONITOR_H_ | 33 #endif // PPAPI_CPP_NETWORK_MONITOR_H_ |
OLD | NEW |