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

Unified Diff: net/base/registry_controlled_domain.cc

Issue 6898026: Eliminate wstring from base/utf_offset_string_conversions.h, net/base/escape.h, and net/base/net_... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: net/base/registry_controlled_domain.cc
===================================================================
--- net/base/registry_controlled_domain.cc (revision 82762)
+++ net/base/registry_controlled_domain.cc (working copy)
@@ -42,6 +42,7 @@
#include "base/logging.h"
#include "base/memory/singleton.h"
#include "base/string_util.h"
+#include "base/utf_string_conversions.h"
#include "googleurl/src/gurl.h"
#include "googleurl/src/url_parse.h"
#include "net/base/net_module.h"
@@ -82,16 +83,6 @@
}
// static
-std::string RegistryControlledDomainService::GetDomainAndRegistry(
- const std::wstring& host) {
- url_canon::CanonHostInfo host_info;
- const std::string canon_host(CanonicalizeHost(host, &host_info));
- if (canon_host.empty() || host_info.IsIPAddress())
- return std::string();
- return GetDomainAndRegistryImpl(canon_host);
-}
-
-// static
bool RegistryControlledDomainService::SameDomainOrHost(const GURL& gurl1,
const GURL& gurl2) {
// See if both URLs have a known domain + registry, and those values are the
@@ -143,20 +134,6 @@
}
// static
-size_t RegistryControlledDomainService::GetRegistryLength(
- const std::wstring& host,
- bool allow_unknown_registries) {
- url_canon::CanonHostInfo host_info;
- const std::string canon_host(CanonicalizeHost(host, &host_info));
- if (canon_host.empty())
- return std::string::npos;
- if (host_info.IsIPAddress())
- return 0;
- return GetInstance()->GetRegistryLengthImpl(canon_host,
- allow_unknown_registries);
-}
-
-// static
RegistryControlledDomainService* RegistryControlledDomainService::GetInstance()
{
if (test_instance_)

Powered by Google App Engine
This is Rietveld 408576698