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

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

Issue 930363002: Remove adapter method on HistoryBackend delegating to AndroidProviderBackend (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 5 years, 10 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 (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_SERVICE_H_ 5 #ifndef CHROME_BROWSER_HISTORY_HISTORY_SERVICE_H_
6 #define CHROME_BROWSER_HISTORY_HISTORY_SERVICE_H_ 6 #define CHROME_BROWSER_HISTORY_HISTORY_SERVICE_H_
7 7
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 420 matching lines...) Expand 10 before | Expand all | Expand 10 after
431 // Observers ----------------------------------------------------------------- 431 // Observers -----------------------------------------------------------------
432 432
433 // Adds/Removes an Observer. 433 // Adds/Removes an Observer.
434 void AddObserver(history::HistoryServiceObserver* observer); 434 void AddObserver(history::HistoryServiceObserver* observer);
435 void RemoveObserver(history::HistoryServiceObserver* observer); 435 void RemoveObserver(history::HistoryServiceObserver* observer);
436 436
437 // Generic Stuff ------------------------------------------------------------- 437 // Generic Stuff -------------------------------------------------------------
438 438
439 // Schedules a HistoryDBTask for running on the history backend thread. See 439 // Schedules a HistoryDBTask for running on the history backend thread. See
440 // HistoryDBTask for details on what this does. Takes ownership of |task|. 440 // HistoryDBTask for details on what this does. Takes ownership of |task|.
441 virtual void ScheduleDBTask(scoped_ptr<history::HistoryDBTask> task, 441 virtual base::CancelableTaskTracker::TaskId ScheduleDBTask(
442 base::CancelableTaskTracker* tracker); 442 scoped_ptr<history::HistoryDBTask> task,
443 base::CancelableTaskTracker* tracker);
443 444
444 // This callback is invoked when favicon change for urls. 445 // This callback is invoked when favicon change for urls.
445 typedef base::Callback<void(const std::set<GURL>&)> OnFaviconChangedCallback; 446 typedef base::Callback<void(const std::set<GURL>&)> OnFaviconChangedCallback;
446 447
447 // Add a callback to the list. The callback will remain registered until the 448 // Add a callback to the list. The callback will remain registered until the
448 // returned Subscription is destroyed. This must occurs before HistoryService 449 // returned Subscription is destroyed. This must occurs before HistoryService
449 // is destroyed. 450 // is destroyed.
450 scoped_ptr<base::CallbackList<void(const std::set<GURL>&)>::Subscription> 451 scoped_ptr<base::CallbackList<void(const std::set<GURL>&)>::Subscription>
451 AddFaviconChangedCallback(const OnFaviconChangedCallback& callback) 452 AddFaviconChangedCallback(const OnFaviconChangedCallback& callback)
452 WARN_UNUSED_RESULT; 453 WARN_UNUSED_RESULT;
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
512 // These are not currently used, hopefully we can do something in the future 513 // These are not currently used, hopefully we can do something in the future
513 // to ensure that the most important things happen first. 514 // to ensure that the most important things happen first.
514 enum SchedulePriority { 515 enum SchedulePriority {
515 PRIORITY_UI, // The highest priority (must respond to UI events). 516 PRIORITY_UI, // The highest priority (must respond to UI events).
516 PRIORITY_NORMAL, // Normal stuff like adding a page. 517 PRIORITY_NORMAL, // Normal stuff like adding a page.
517 PRIORITY_LOW, // Low priority things like indexing or expiration. 518 PRIORITY_LOW, // Low priority things like indexing or expiration.
518 }; 519 };
519 520
520 private: 521 private:
521 class BackendDelegate; 522 class BackendDelegate;
522 #if defined(OS_ANDROID)
523 friend class AndroidHistoryProviderService;
524 #endif
525 friend class base::RefCountedThreadSafe<HistoryService>; 523 friend class base::RefCountedThreadSafe<HistoryService>;
526 friend class BackendDelegate; 524 friend class BackendDelegate;
527 friend class FaviconService; 525 friend class FaviconService;
528 friend class history::HistoryBackend; 526 friend class history::HistoryBackend;
529 friend class history::HistoryQueryTest; 527 friend class history::HistoryQueryTest;
530 friend class HistoryOperation; 528 friend class HistoryOperation;
531 friend class HistoryQuickProviderTest; 529 friend class HistoryQuickProviderTest;
532 friend class history::HistoryTest; 530 friend class history::HistoryTest;
533 friend class HistoryURLProvider; 531 friend class HistoryURLProvider;
534 friend class HistoryURLProviderTest; 532 friend class HistoryURLProviderTest;
(...skipping 293 matching lines...) Expand 10 before | Expand all | Expand 10 after
828 826
829 history::DeleteDirectiveHandler delete_directive_handler_; 827 history::DeleteDirectiveHandler delete_directive_handler_;
830 828
831 // All vended weak pointers are invalidated in Cleanup(). 829 // All vended weak pointers are invalidated in Cleanup().
832 base::WeakPtrFactory<HistoryService> weak_ptr_factory_; 830 base::WeakPtrFactory<HistoryService> weak_ptr_factory_;
833 831
834 DISALLOW_COPY_AND_ASSIGN(HistoryService); 832 DISALLOW_COPY_AND_ASSIGN(HistoryService);
835 }; 833 };
836 834
837 #endif // CHROME_BROWSER_HISTORY_HISTORY_SERVICE_H_ 835 #endif // CHROME_BROWSER_HISTORY_HISTORY_SERVICE_H_
OLDNEW
« no previous file with comments | « chrome/browser/history/history_backend_android.cc ('k') | chrome/browser/history/history_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698