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

Side by Side Diff: chrome/browser/ui/app_list/search/common/webservice_cache.h

Issue 671653002: Standardize usage of virtual/override/final in chrome/browser/ui/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_UI_APP_LIST_SEARCH_COMMON_WEBSERVICE_CACHE_H_ 5 #ifndef CHROME_BROWSER_UI_APP_LIST_SEARCH_COMMON_WEBSERVICE_CACHE_H_
6 #define CHROME_BROWSER_UI_APP_LIST_SEARCH_COMMON_WEBSERVICE_CACHE_H_ 6 #define CHROME_BROWSER_UI_APP_LIST_SEARCH_COMMON_WEBSERVICE_CACHE_H_
7 7
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 29 matching lines...) Expand all
40 // search sessions. 40 // search sessions.
41 class WebserviceCache : public KeyedService, 41 class WebserviceCache : public KeyedService,
42 public base::SupportsWeakPtr<WebserviceCache> { 42 public base::SupportsWeakPtr<WebserviceCache> {
43 public: 43 public:
44 enum QueryType { 44 enum QueryType {
45 WEBSTORE = 0, 45 WEBSTORE = 0,
46 PEOPLE = 1 46 PEOPLE = 1
47 }; 47 };
48 48
49 explicit WebserviceCache(content::BrowserContext* context); 49 explicit WebserviceCache(content::BrowserContext* context);
50 virtual ~WebserviceCache(); 50 ~WebserviceCache() override;
51 51
52 // Checks the current cache and returns the value for the |query| if it's 52 // Checks the current cache and returns the value for the |query| if it's
53 // valid. Otherwise an CacheResult object with the result field set to NULL. 53 // valid. Otherwise an CacheResult object with the result field set to NULL.
54 // A query consists of a query 'type' and the query itself. The two current 54 // A query consists of a query 'type' and the query itself. The two current
55 // types of queries supported are webstore queries and people search queries. 55 // types of queries supported are webstore queries and people search queries.
56 // The type silos the query into it's own separate domain, preventing any 56 // The type silos the query into it's own separate domain, preventing any
57 // mixing of the queries. 57 // mixing of the queries.
58 const CacheResult Get(QueryType type, const std::string& query); 58 const CacheResult Get(QueryType type, const std::string& query);
59 59
60 // Puts the new result to the query. 60 // Puts the new result to the query.
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
104 scoped_refptr<DictionaryDataStore> data_store_; 104 scoped_refptr<DictionaryDataStore> data_store_;
105 105
106 bool cache_loaded_; 106 bool cache_loaded_;
107 107
108 DISALLOW_COPY_AND_ASSIGN(WebserviceCache); 108 DISALLOW_COPY_AND_ASSIGN(WebserviceCache);
109 }; 109 };
110 110
111 } // namespace app_list 111 } // namespace app_list
112 112
113 #endif // CHROME_BROWSER_UI_APP_LIST_SEARCH_COMMON_WEBSERVICE_CACHE_H_ 113 #endif // CHROME_BROWSER_UI_APP_LIST_SEARCH_COMMON_WEBSERVICE_CACHE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698