OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 CHROME_BROWSER_CHROMEOS_NET_NETWORK_PORTAL_DETECTOR_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_NET_NETWORK_PORTAL_DETECTOR_H_ |
6 #define CHROME_BROWSER_CHROMEOS_NET_NETWORK_PORTAL_DETECTOR_H_ | 6 #define CHROME_BROWSER_CHROMEOS_NET_NETWORK_PORTAL_DETECTOR_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "net/url_request/url_fetcher.h" | 9 #include "net/url_request/url_fetcher.h" |
10 | 10 |
11 namespace chromeos { | 11 namespace chromeos { |
12 | 12 |
13 class NetworkState; | 13 class NetworkState; |
14 | 14 |
15 // This class handles all notifications about network changes from | 15 // This class handles all notifications about network changes from |
16 // NetworkLibrary and delegates portal detection for the active | 16 // the NetworkStateHandler and delegates portal detection for the active |
17 // network to CaptivePortalService. | 17 // network to CaptivePortalService. |
18 class NetworkPortalDetector { | 18 class NetworkPortalDetector { |
19 public: | 19 public: |
20 enum CaptivePortalStatus { | 20 enum CaptivePortalStatus { |
21 CAPTIVE_PORTAL_STATUS_UNKNOWN = 0, | 21 CAPTIVE_PORTAL_STATUS_UNKNOWN = 0, |
22 CAPTIVE_PORTAL_STATUS_OFFLINE = 1, | 22 CAPTIVE_PORTAL_STATUS_OFFLINE = 1, |
23 CAPTIVE_PORTAL_STATUS_ONLINE = 2, | 23 CAPTIVE_PORTAL_STATUS_ONLINE = 2, |
24 CAPTIVE_PORTAL_STATUS_PORTAL = 3, | 24 CAPTIVE_PORTAL_STATUS_PORTAL = 3, |
25 CAPTIVE_PORTAL_STATUS_PROXY_AUTH_REQUIRED = 4, | 25 CAPTIVE_PORTAL_STATUS_PROXY_AUTH_REQUIRED = 4, |
26 CAPTIVE_PORTAL_STATUS_COUNT | 26 CAPTIVE_PORTAL_STATUS_COUNT |
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
113 NetworkPortalDetector(); | 113 NetworkPortalDetector(); |
114 virtual ~NetworkPortalDetector(); | 114 virtual ~NetworkPortalDetector(); |
115 | 115 |
116 private: | 116 private: |
117 DISALLOW_COPY_AND_ASSIGN(NetworkPortalDetector); | 117 DISALLOW_COPY_AND_ASSIGN(NetworkPortalDetector); |
118 }; | 118 }; |
119 | 119 |
120 } // namespace chromeos | 120 } // namespace chromeos |
121 | 121 |
122 #endif // CHROME_BROWSER_CHROMEOS_NET_NETWORK_PORTAL_DETECTOR_H_ | 122 #endif // CHROME_BROWSER_CHROMEOS_NET_NETWORK_PORTAL_DETECTOR_H_ |
OLD | NEW |