| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 COMPONENTS_HISTORY_CORE_BROWSER_HISTORY_MODEL_WORKER_H_ | 5 #ifndef COMPONENTS_HISTORY_CORE_BROWSER_HISTORY_MODEL_WORKER_H_ |
| 6 #define COMPONENTS_HISTORY_CORE_BROWSER_HISTORY_MODEL_WORKER_H_ | 6 #define COMPONENTS_HISTORY_CORE_BROWSER_HISTORY_MODEL_WORKER_H_ |
| 7 | 7 |
| 8 #include "base/callback_forward.h" | 8 #include "base/callback_forward.h" |
| 9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| 11 #include "base/memory/ref_counted.h" | 11 #include "base/memory/ref_counted.h" |
| 12 #include "base/memory/weak_ptr.h" | 12 #include "base/memory/weak_ptr.h" |
| 13 #include "base/task/cancelable_task_tracker.h" | 13 #include "base/task/cancelable_task_tracker.h" |
| 14 #include "components/history/core/browser/history_db_task.h" | 14 #include "components/history/core/browser/history_db_task.h" |
| 15 #include "components/history/core/browser/history_service.h" | 15 #include "components/history/core/browser/history_service.h" |
| 16 #include "sync/internal_api/public/engine/model_safe_worker.h" | 16 #include "components/sync/engine/model_safe_worker.h" |
| 17 | 17 |
| 18 namespace history { | 18 namespace history { |
| 19 class HistoryService; | 19 class HistoryService; |
| 20 } | 20 } |
| 21 | 21 |
| 22 namespace browser_sync { | 22 namespace browser_sync { |
| 23 | 23 |
| 24 // A syncer::ModelSafeWorker for history models that accepts requests | 24 // A syncer::ModelSafeWorker for history models that accepts requests |
| 25 // from the syncapi that need to be fulfilled on the history thread. | 25 // from the syncapi that need to be fulfilled on the history thread. |
| 26 class HistoryModelWorker : public syncer::ModelSafeWorker { | 26 class HistoryModelWorker : public syncer::ModelSafeWorker { |
| (...skipping 26 matching lines...) Expand all Loading... |
| 53 // Helper object to make sure we don't leave tasks running on the history | 53 // Helper object to make sure we don't leave tasks running on the history |
| 54 // thread. | 54 // thread. |
| 55 std::unique_ptr<base::CancelableTaskTracker> cancelable_tracker_; | 55 std::unique_ptr<base::CancelableTaskTracker> cancelable_tracker_; |
| 56 | 56 |
| 57 DISALLOW_COPY_AND_ASSIGN(HistoryModelWorker); | 57 DISALLOW_COPY_AND_ASSIGN(HistoryModelWorker); |
| 58 }; | 58 }; |
| 59 | 59 |
| 60 } // namespace browser_sync | 60 } // namespace browser_sync |
| 61 | 61 |
| 62 #endif // COMPONENTS_HISTORY_CORE_BROWSER_HISTORY_MODEL_WORKER_H_ | 62 #endif // COMPONENTS_HISTORY_CORE_BROWSER_HISTORY_MODEL_WORKER_H_ |
| OLD | NEW |