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

Unified Diff: chrome/browser/history/expire_history_backend.h

Issue 285233012: Abstract history dependencies on bookmarks through HistoryClient (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix unit tests Created 6 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/history/expire_history_backend.h
diff --git a/chrome/browser/history/expire_history_backend.h b/chrome/browser/history/expire_history_backend.h
index e88da3e5c831e4d0590550ce743be0c0e617687f..1792d3fe03ee388c3abdca09d2ef75674f6ce2f0 100644
--- a/chrome/browser/history/expire_history_backend.h
+++ b/chrome/browser/history/expire_history_backend.h
@@ -16,13 +16,13 @@
#include "base/time/time.h"
#include "chrome/browser/history/history_types.h"
-class BookmarkService;
class GURL;
class TestingProfile;
namespace history {
class ArchivedDatabase;
+class HistoryClient;
class HistoryDatabase;
struct HistoryDetails;
class ThumbnailDatabase;
@@ -66,11 +66,11 @@ typedef std::vector<const ExpiringVisitsReader*> ExpiringVisitsReaders;
class ExpireHistoryBackend {
public:
// The delegate pointer must be non-NULL. We will NOT take ownership of it.
- // BookmarkService may be NULL. The BookmarkService is used when expiring
- // URLs so that we don't remove any URLs or favicons that are bookmarked
- // (visits are removed though).
+ // HistoryClient may be NULL. The HistoryClient is used when expiring URLS so
+ // that we don't remove any URLs or favicons that are bookmarked (visits are
+ // removed though).
ExpireHistoryBackend(BroadcastNotificationDelegate* delegate,
- BookmarkService* bookmark_service);
+ HistoryClient* history_client);
~ExpireHistoryBackend();
// Completes initialization by setting the databases that this class will use.
@@ -251,9 +251,9 @@ class ExpireHistoryBackend {
// and deletes items. For example, URLs with no visits.
void ParanoidExpireHistory();
- // Returns the BookmarkService, blocking until it is loaded. This may return
+ // Returns the HistoryClient, blocking until it is loaded. This may return
// NULL.
- BookmarkService* GetBookmarkService();
+ HistoryClient* GetHistoryClient();
// Initializes periodic expiration work queue by populating it with with tasks
// for all known readers.
@@ -298,11 +298,10 @@ class ExpireHistoryBackend {
scoped_ptr<ExpiringVisitsReader> all_visits_reader_;
scoped_ptr<ExpiringVisitsReader> auto_subframe_visits_reader_;
- // The BookmarkService; may be null. This is owned by the Profile.
+ // The HistoryClient; may be NULL.
//
- // Use GetBookmarkService to access this, which makes sure the service is
- // loaded.
- BookmarkService* bookmark_service_;
+ // Use GetHistoryClient to access this, which makes sure the data is loaded.
+ HistoryClient* history_client_;
DISALLOW_COPY_AND_ASSIGN(ExpireHistoryBackend);
};

Powered by Google App Engine
This is Rietveld 408576698