OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 // This class contains common functionality for search-based autocomplete | 5 // This class contains common functionality for search-based autocomplete |
6 // providers. Search provider and zero suggest provider both use it for common | 6 // providers. Search provider and zero suggest provider both use it for common |
7 // functionality. | 7 // functionality. |
8 | 8 |
9 #ifndef COMPONENTS_OMNIBOX_BROWSER_BASE_SEARCH_PROVIDER_H_ | 9 #ifndef COMPONENTS_OMNIBOX_BROWSER_BASE_SEARCH_PROVIDER_H_ |
10 #define COMPONENTS_OMNIBOX_BROWSER_BASE_SEARCH_PROVIDER_H_ | 10 #define COMPONENTS_OMNIBOX_BROWSER_BASE_SEARCH_PROVIDER_H_ |
(...skipping 13 matching lines...) Expand all Loading... |
24 #include "components/omnibox/browser/autocomplete_provider.h" | 24 #include "components/omnibox/browser/autocomplete_provider.h" |
25 #include "components/omnibox/browser/search_suggestion_parser.h" | 25 #include "components/omnibox/browser/search_suggestion_parser.h" |
26 | 26 |
27 class AutocompleteProviderClient; | 27 class AutocompleteProviderClient; |
28 class GURL; | 28 class GURL; |
29 class SearchTermsData; | 29 class SearchTermsData; |
30 class SuggestionDeletionHandler; | 30 class SuggestionDeletionHandler; |
31 class TemplateURL; | 31 class TemplateURL; |
32 | 32 |
33 namespace base { | 33 namespace base { |
34 class DictionaryValue; | |
35 class ListValue; | |
36 class Value; | 34 class Value; |
37 } | 35 } |
38 | 36 |
39 // Base functionality for receiving suggestions from a search engine. | 37 // Base functionality for receiving suggestions from a search engine. |
40 // This class is abstract and should only be used as a base for other | 38 // This class is abstract and should only be used as a base for other |
41 // autocomplete providers utilizing its functionality. | 39 // autocomplete providers utilizing its functionality. |
42 class BaseSearchProvider : public AutocompleteProvider { | 40 class BaseSearchProvider : public AutocompleteProvider { |
43 public: | 41 public: |
44 // ID used in creating URLFetcher for default provider's suggest results. | 42 // ID used in creating URLFetcher for default provider's suggest results. |
45 static const int kDefaultProviderURLFetcherID; | 43 static const int kDefaultProviderURLFetcherID; |
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
260 | 258 |
261 // Each deletion handler in this vector corresponds to an outstanding request | 259 // Each deletion handler in this vector corresponds to an outstanding request |
262 // that a server delete a personalized suggestion. Making this a ScopedVector | 260 // that a server delete a personalized suggestion. Making this a ScopedVector |
263 // causes us to auto-cancel all such requests on shutdown. | 261 // causes us to auto-cancel all such requests on shutdown. |
264 SuggestionDeletionHandlers deletion_handlers_; | 262 SuggestionDeletionHandlers deletion_handlers_; |
265 | 263 |
266 DISALLOW_COPY_AND_ASSIGN(BaseSearchProvider); | 264 DISALLOW_COPY_AND_ASSIGN(BaseSearchProvider); |
267 }; | 265 }; |
268 | 266 |
269 #endif // COMPONENTS_OMNIBOX_BROWSER_BASE_SEARCH_PROVIDER_H_ | 267 #endif // COMPONENTS_OMNIBOX_BROWSER_BASE_SEARCH_PROVIDER_H_ |
OLD | NEW |