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

Side by Side Diff: net/base/registry_controlled_domain.h

Issue 6969077: net: Add NET_API to net/base (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 //* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ 1 //* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* ***** BEGIN LICENSE BLOCK ***** 2 /* ***** BEGIN LICENSE BLOCK *****
3 * Version: MPL 1.1/GPL 2.0/LGPL 2.1 3 * Version: MPL 1.1/GPL 2.0/LGPL 2.1
4 * 4 *
5 * The contents of this file are subject to the Mozilla Public License Version 5 * The contents of this file are subject to the Mozilla Public License Version
6 * 1.1 (the "License"); you may not use this file except in compliance with 6 * 1.1 (the "License"); you may not use this file except in compliance with
7 * the License. You may obtain a copy of the License at 7 * the License. You may obtain a copy of the License at
8 * http://www.mozilla.org/MPL/ 8 * http://www.mozilla.org/MPL/
9 * 9 *
10 * Software distributed under the License is distributed on an "AS IS" basis, 10 * Software distributed under the License is distributed on an "AS IS" basis,
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 GURL to normalize rules, and validating the rules. 107 GURL to normalize rules, and validating the rules.
108 */ 108 */
109 109
110 #ifndef NET_BASE_REGISTRY_CONTROLLED_DOMAIN_H_ 110 #ifndef NET_BASE_REGISTRY_CONTROLLED_DOMAIN_H_
111 #define NET_BASE_REGISTRY_CONTROLLED_DOMAIN_H_ 111 #define NET_BASE_REGISTRY_CONTROLLED_DOMAIN_H_
112 #pragma once 112 #pragma once
113 113
114 #include <string> 114 #include <string>
115 115
116 #include "base/basictypes.h" 116 #include "base/basictypes.h"
117 #include "net/base/net_api.h"
117 118
118 class GURL; 119 class GURL;
119 120
120 template <typename T> 121 template <typename T>
121 struct DefaultSingletonTraits; 122 struct DefaultSingletonTraits;
122 struct DomainRule; 123 struct DomainRule;
123 124
124 namespace net { 125 namespace net {
125 126
126 struct RegistryControlledDomainServiceSingletonTraits; 127 struct RegistryControlledDomainServiceSingletonTraits;
127 128
128 // This class is a singleton. 129 // This class is a singleton.
129 class RegistryControlledDomainService { 130 class NET_API RegistryControlledDomainService {
130 public: 131 public:
131 ~RegistryControlledDomainService() { } 132 ~RegistryControlledDomainService() { }
132 133
133 // Returns the registered, organization-identifying host and all its registry 134 // Returns the registered, organization-identifying host and all its registry
134 // information, but no subdomains, from the given GURL. Returns an empty 135 // information, but no subdomains, from the given GURL. Returns an empty
135 // string if the GURL is invalid, has no host (e.g. a file: URL), has multiple 136 // string if the GURL is invalid, has no host (e.g. a file: URL), has multiple
136 // trailing dots, is an IP address, has only one subcomponent (i.e. no dots 137 // trailing dots, is an IP address, has only one subcomponent (i.e. no dots
137 // other than leading/trailing ones), or is itself a recognized registry 138 // other than leading/trailing ones), or is itself a recognized registry
138 // identifier. If no matching rule is found in the effective-TLD data (or in 139 // identifier. If no matching rule is found in the effective-TLD data (or in
139 // the default data, if the resource failed to load), the last subcomponent of 140 // the default data, if the resource failed to load), the last subcomponent of
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
230 231
231 // Function that returns a DomainRule given a domain. 232 // Function that returns a DomainRule given a domain.
232 FindDomainPtr find_domain_function_; 233 FindDomainPtr find_domain_function_;
233 234
234 DISALLOW_COPY_AND_ASSIGN(RegistryControlledDomainService); 235 DISALLOW_COPY_AND_ASSIGN(RegistryControlledDomainService);
235 }; 236 };
236 237
237 } // namespace net 238 } // namespace net
238 239
239 #endif // NET_BASE_REGISTRY_CONTROLLED_DOMAIN_H_ 240 #endif // NET_BASE_REGISTRY_CONTROLLED_DOMAIN_H_
OLDNEW
« base/compiler_specific.h ('K') | « net/base/pem_tokenizer.h ('k') | net/base/sdch_filter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698