summaryrefslogtreecommitdiffstats
path: root/components/captive_portal/captive_portal_types.h
diff options
context:
space:
mode:
authorstevenjb@chromium.org <stevenjb@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-04-29 18:05:44 +0000
committerstevenjb@chromium.org <stevenjb@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-04-29 18:05:44 +0000
commitb1a160ded85df2e7911553e81900b7cc5f53f034 (patch)
treef99bcca20d28f94e0def1682e9616b325b2ea7b9 /components/captive_portal/captive_portal_types.h
parent291edd303fa204030ae793bb4923f26a56dbdea2 (diff)
downloadchromium_src-b1a160ded85df2e7911553e81900b7cc5f53f034.zip
chromium_src-b1a160ded85df2e7911553e81900b7cc5f53f034.tar.gz
chromium_src-b1a160ded85df2e7911553e81900b7cc5f53f034.tar.bz2
Move CaptivePortalDetector to src/chomponents/captive_portal
BUG=364894 For trivial header file renaming in c/b and c/test: R=mmenke@chromium.org, ygorshenin@chromium.org TBR=sky@chromium.org Review URL: https://codereview.chromium.org/242483003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@266920 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'components/captive_portal/captive_portal_types.h')
-rw-r--r--components/captive_portal/captive_portal_types.h31
1 files changed, 31 insertions, 0 deletions
diff --git a/components/captive_portal/captive_portal_types.h b/components/captive_portal/captive_portal_types.h
new file mode 100644
index 0000000..57319d7
--- /dev/null
+++ b/components/captive_portal/captive_portal_types.h
@@ -0,0 +1,31 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef NET_CAPTIVE_PORTAL_CAPTIVE_PORTAL_TYPES_H_
+#define NET_CAPTIVE_PORTAL_CAPTIVE_PORTAL_TYPES_H_
+
+#include <string>
+
+#include "components/captive_portal/captive_portal_export.h"
+
+namespace captive_portal {
+
+// Possible results of an attempt to detect a captive portal.
+enum CaptivePortalResult {
+ // There's a confirmed connection to the Internet.
+ RESULT_INTERNET_CONNECTED,
+ // The URL request received a network or HTTP error, or a non-HTTP response.
+ RESULT_NO_RESPONSE,
+ // The URL request apparently encountered a captive portal. It received a
+ // a valid HTTP response with a 2xx other than 204, 3xx, or 511 status code.
+ RESULT_BEHIND_CAPTIVE_PORTAL,
+ RESULT_COUNT
+};
+
+CAPTIVE_PORTAL_EXPORT extern std::string CaptivePortalResultToString(
+ CaptivePortalResult result);
+
+} // namespace captive_portal
+
+#endif // NET_CAPTIVE_PORTAL_CAPTIVE_PORTAL_TYPES_H_