OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_SYNC_ENGINE_IMPL_MODEL_TYPE_WORKER_H_ | 5 #ifndef COMPONENTS_SYNC_ENGINE_IMPL_MODEL_TYPE_WORKER_H_ |
6 #define COMPONENTS_SYNC_ENGINE_IMPL_MODEL_TYPE_WORKER_H_ | 6 #define COMPONENTS_SYNC_ENGINE_IMPL_MODEL_TYPE_WORKER_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 | 9 |
10 #include <map> | 10 #include <map> |
11 #include <memory> | 11 #include <memory> |
12 #include <string> | 12 #include <string> |
13 | 13 |
14 #include "base/memory/weak_ptr.h" | 14 #include "base/memory/weak_ptr.h" |
15 #include "base/threading/thread_checker.h" | 15 #include "base/threading/thread_checker.h" |
16 #include "components/sync/base/cryptographer.h" | 16 #include "components/sync/base/cryptographer.h" |
17 #include "components/sync/base/model_type.h" | 17 #include "components/sync/base/model_type.h" |
18 #include "components/sync/engine/commit_queue.h" | 18 #include "components/sync/engine/commit_queue.h" |
19 #include "components/sync/engine/non_blocking_sync_common.h" | 19 #include "components/sync/engine/non_blocking_sync_common.h" |
20 #include "components/sync/engine/sync_encryption_handler.h" | 20 #include "components/sync/engine/sync_encryption_handler.h" |
21 #include "components/sync/engine_impl/commit_contributor.h" | 21 #include "components/sync/engine_impl/commit_contributor.h" |
22 #include "components/sync/engine_impl/cycle/data_type_debug_info_emitter.h" | 22 #include "components/sync/engine_impl/cycle/data_type_debug_info_emitter.h" |
23 #include "components/sync/engine_impl/nudge_handler.h" | 23 #include "components/sync/engine_impl/nudge_handler.h" |
24 #include "components/sync/engine_impl/update_handler.h" | 24 #include "components/sync/engine_impl/update_handler.h" |
25 #include "components/sync/protocol/model_type_state.pb.h" | 25 #include "components/sync/protocol/model_type_state.pb.h" |
26 #include "components/sync/protocol/sync.pb.h" | 26 #include "components/sync/protocol/sync.pb.h" |
27 | 27 |
28 namespace base { | |
29 class SingleThreadTaskRunner; | |
30 } | |
31 | |
32 namespace syncer { | 28 namespace syncer { |
33 | 29 |
34 class ModelTypeProcessor; | 30 class ModelTypeProcessor; |
35 class WorkerEntityTracker; | 31 class WorkerEntityTracker; |
36 | 32 |
37 // A smart cache for sync types that use message passing (rather than | 33 // A smart cache for sync types that use message passing (rather than |
38 // transactions and the syncable::Directory) to communicate with the sync | 34 // transactions and the syncable::Directory) to communicate with the sync |
39 // thread. | 35 // thread. |
40 // | 36 // |
41 // When the non-blocking sync type wants to talk with the sync server, it will | 37 // When the non-blocking sync type wants to talk with the sync server, it will |
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
203 // Whether there are outstanding encrypted updates in |entities_|. | 199 // Whether there are outstanding encrypted updates in |entities_|. |
204 bool has_encrypted_updates_ = false; | 200 bool has_encrypted_updates_ = false; |
205 | 201 |
206 base::ThreadChecker thread_checker_; | 202 base::ThreadChecker thread_checker_; |
207 base::WeakPtrFactory<ModelTypeWorker> weak_ptr_factory_; | 203 base::WeakPtrFactory<ModelTypeWorker> weak_ptr_factory_; |
208 }; | 204 }; |
209 | 205 |
210 } // namespace syncer | 206 } // namespace syncer |
211 | 207 |
212 #endif // COMPONENTS_SYNC_ENGINE_IMPL_MODEL_TYPE_WORKER_H_ | 208 #endif // COMPONENTS_SYNC_ENGINE_IMPL_MODEL_TYPE_WORKER_H_ |
OLD | NEW |