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

Side by Side Diff: chrome/browser/history/in_memory_url_index.h

Issue 10071032: RefCounted types should not have public destructors, chrome/browser/ part 1 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Implementation fixes Created 8 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/history/history_types.h ('k') | chrome/browser/history/in_memory_url_index.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_HISTORY_IN_MEMORY_URL_INDEX_H_ 5 #ifndef CHROME_BROWSER_HISTORY_IN_MEMORY_URL_INDEX_H_
6 #define CHROME_BROWSER_HISTORY_IN_MEMORY_URL_INDEX_H_ 6 #define CHROME_BROWSER_HISTORY_IN_MEMORY_URL_INDEX_H_
7 #pragma once 7 #pragma once
8 8
9 #include <functional> 9 #include <functional>
10 #include <map> 10 #include <map>
(...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after
157 // Creating one of me without a history path is not allowed (tests excepted). 157 // Creating one of me without a history path is not allowed (tests excepted).
158 InMemoryURLIndex(); 158 InMemoryURLIndex();
159 159
160 // HistoryDBTask used to rebuild our private data from the history database. 160 // HistoryDBTask used to rebuild our private data from the history database.
161 class RebuildPrivateDataFromHistoryDBTask : public HistoryDBTask { 161 class RebuildPrivateDataFromHistoryDBTask : public HistoryDBTask {
162 public: 162 public:
163 explicit RebuildPrivateDataFromHistoryDBTask( 163 explicit RebuildPrivateDataFromHistoryDBTask(
164 InMemoryURLIndex* index, 164 InMemoryURLIndex* index,
165 const std::string& languages, 165 const std::string& languages,
166 const std::set<std::string>& scheme_whitelist); 166 const std::set<std::string>& scheme_whitelist);
167 virtual ~RebuildPrivateDataFromHistoryDBTask();
168 167
169 virtual bool RunOnDBThread(HistoryBackend* backend, 168 virtual bool RunOnDBThread(HistoryBackend* backend,
170 history::HistoryDatabase* db) OVERRIDE; 169 history::HistoryDatabase* db) OVERRIDE;
171 virtual void DoneRunOnMainThread() OVERRIDE; 170 virtual void DoneRunOnMainThread() OVERRIDE;
172 171
173 private: 172 private:
173 virtual ~RebuildPrivateDataFromHistoryDBTask();
174
174 InMemoryURLIndex* index_; // Call back to this index at completion. 175 InMemoryURLIndex* index_; // Call back to this index at completion.
175 std::string languages_; // Languages for word-breaking. 176 std::string languages_; // Languages for word-breaking.
176 std::set<std::string> scheme_whitelist_; // Schemes to be indexed. 177 std::set<std::string> scheme_whitelist_; // Schemes to be indexed.
177 bool succeeded_; // Indicates if the rebuild was successful. 178 bool succeeded_; // Indicates if the rebuild was successful.
178 scoped_refptr<URLIndexPrivateData> data_; // The rebuilt private data. 179 scoped_refptr<URLIndexPrivateData> data_; // The rebuilt private data.
179 180
180 DISALLOW_COPY_AND_ASSIGN(RebuildPrivateDataFromHistoryDBTask); 181 DISALLOW_COPY_AND_ASSIGN(RebuildPrivateDataFromHistoryDBTask);
181 }; 182 };
182 183
183 // Initializes all index data members in preparation for restoring the index 184 // Initializes all index data members in preparation for restoring the index
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
290 // TODO(mrossetti): Eliminate once the transition to SQLite has been done. 291 // TODO(mrossetti): Eliminate once the transition to SQLite has been done.
291 // http://crbug.com/83659 292 // http://crbug.com/83659
292 bool needs_to_be_cached_; 293 bool needs_to_be_cached_;
293 294
294 DISALLOW_COPY_AND_ASSIGN(InMemoryURLIndex); 295 DISALLOW_COPY_AND_ASSIGN(InMemoryURLIndex);
295 }; 296 };
296 297
297 } // namespace history 298 } // namespace history
298 299
299 #endif // CHROME_BROWSER_HISTORY_IN_MEMORY_URL_INDEX_H_ 300 #endif // CHROME_BROWSER_HISTORY_IN_MEMORY_URL_INDEX_H_
OLDNEW
« no previous file with comments | « chrome/browser/history/history_types.h ('k') | chrome/browser/history/in_memory_url_index.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698