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 CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_PARSER_H_ | 5 #ifndef CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_PARSER_H_ |
6 #define CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_PARSER_H_ | 6 #define CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_PARSER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 19 matching lines...) Expand all Loading... | |
30 | 30 |
31 // Decodes the chunk of data representing a TemplateURL, creates the | 31 // Decodes the chunk of data representing a TemplateURL, creates the |
32 // TemplateURL, and returns it. The caller owns the returned object. Returns | 32 // TemplateURL, and returns it. The caller owns the returned object. Returns |
33 // NULL if data does not describe a valid TemplateURL, the URLs referenced do | 33 // NULL if data does not describe a valid TemplateURL, the URLs referenced do |
34 // not point to valid http/https resources, or for some other reason we do not | 34 // not point to valid http/https resources, or for some other reason we do not |
35 // support the described TemplateURL. |parameter_filter| can be used if you | 35 // support the described TemplateURL. |parameter_filter| can be used if you |
36 // want to filter some parameters out of the URL. For example, when importing | 36 // want to filter some parameters out of the URL. For example, when importing |
37 // from another browser, we remove any parameter identifying that browser. If | 37 // from another browser, we remove any parameter identifying that browser. If |
38 // set to NULL, the URL is not modified. | 38 // set to NULL, the URL is not modified. |
39 static TemplateURL* Parse(Profile* profile, | 39 static TemplateURL* Parse(Profile* profile, |
40 bool show_in_default_list, | |
sky
2012/04/05 03:42:15
nit: use an enum.
Peter Kasting
2012/04/05 19:52:21
Ended up not doing this because it would require a
| |
40 const char* data, | 41 const char* data, |
41 size_t length, | 42 size_t length, |
42 ParameterFilter* parameter_filter); | 43 ParameterFilter* parameter_filter); |
43 | 44 |
44 private: | 45 private: |
45 // No one should create one of these. | 46 // No one should create one of these. |
46 TemplateURLParser(); | 47 TemplateURLParser(); |
47 | 48 |
48 DISALLOW_COPY_AND_ASSIGN(TemplateURLParser); | 49 DISALLOW_COPY_AND_ASSIGN(TemplateURLParser); |
49 }; | 50 }; |
50 | 51 |
51 #endif // CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_PARSER_H_ | 52 #endif // CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_PARSER_H_ |
OLD | NEW |