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

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

Issue 10067018: Add PrerenderLocalPredictor, which will eventually perform (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: 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
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_HISTORY_BACKEND_H_ 5 #ifndef CHROME_BROWSER_HISTORY_HISTORY_BACKEND_H_
6 #define CHROME_BROWSER_HISTORY_HISTORY_BACKEND_H_ 6 #define CHROME_BROWSER_HISTORY_HISTORY_BACKEND_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 #include <utility> 10 #include <utility>
(...skipping 360 matching lines...) Expand 10 before | Expand all | Expand 10 after
371 #if defined(UNIT_TEST) 371 #if defined(UNIT_TEST)
372 HistoryDatabase* db() const { return db_.get(); } 372 HistoryDatabase* db() const { return db_.get(); }
373 373
374 ExpireHistoryBackend* expire_backend() { return &expirer_; } 374 ExpireHistoryBackend* expire_backend() { return &expirer_; }
375 #endif 375 #endif
376 376
377 // Returns true if the passed visit time is already expired (used by the sync 377 // Returns true if the passed visit time is already expired (used by the sync
378 // code to avoid syncing visits that would immediately be expired). 378 // code to avoid syncing visits that would immediately be expired).
379 virtual bool IsExpiredVisitTime(const base::Time& time); 379 virtual bool IsExpiredVisitTime(const base::Time& time);
380 380
381 // Adds or removes observers for the VisitDatabase. Should be run in the
382 // thread in which the observer would like to be notified.
383 void AddVisitDatabaseObserver(VisitDatabaseObserver* observer);
384 void RemoveVisitDatabaseObserver(VisitDatabaseObserver* observer);
385
381 protected: 386 protected:
382 virtual ~HistoryBackend(); 387 virtual ~HistoryBackend();
383 388
384 private: 389 private:
385 friend class base::RefCountedThreadSafe<HistoryBackend>; 390 friend class base::RefCountedThreadSafe<HistoryBackend>;
386 friend class CommitLaterTask; // The commit task needs to call Commit(). 391 friend class CommitLaterTask; // The commit task needs to call Commit().
387 friend class HistoryBackendTest; 392 friend class HistoryBackendTest;
388 friend class HistoryTest; // So the unit tests can poke our innards. 393 friend class HistoryTest; // So the unit tests can poke our innards.
389 FRIEND_TEST_ALL_PREFIXES(HistoryBackendTest, DeleteAll); 394 FRIEND_TEST_ALL_PREFIXES(HistoryBackendTest, DeleteAll);
390 FRIEND_TEST_ALL_PREFIXES(HistoryBackendTest, DeleteAllThenAddData); 395 FRIEND_TEST_ALL_PREFIXES(HistoryBackendTest, DeleteAllThenAddData);
(...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after
678 // Publishes the history to all indexers which are registered to receive 683 // Publishes the history to all indexers which are registered to receive
679 // history data from us. Can be NULL if there are no listeners. 684 // history data from us. Can be NULL if there are no listeners.
680 scoped_ptr<HistoryPublisher> history_publisher_; 685 scoped_ptr<HistoryPublisher> history_publisher_;
681 686
682 DISALLOW_COPY_AND_ASSIGN(HistoryBackend); 687 DISALLOW_COPY_AND_ASSIGN(HistoryBackend);
683 }; 688 };
684 689
685 } // namespace history 690 } // namespace history
686 691
687 #endif // CHROME_BROWSER_HISTORY_HISTORY_BACKEND_H_ 692 #endif // CHROME_BROWSER_HISTORY_HISTORY_BACKEND_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698