| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_DRIVER_GLUE_SYNC_BACKEND_HOST_IMPL_H_ | 5 #ifndef COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_HOST_IMPL_H_ |
| 6 #define COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_HOST_IMPL_H_ | 6 #define COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_HOST_IMPL_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <map> | 10 #include <map> |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 71 void ActivateDirectoryDataType(ModelType type, | 71 void ActivateDirectoryDataType(ModelType type, |
| 72 ModelSafeGroup group, | 72 ModelSafeGroup group, |
| 73 ChangeProcessor* change_processor) override; | 73 ChangeProcessor* change_processor) override; |
| 74 void DeactivateDirectoryDataType(ModelType type) override; | 74 void DeactivateDirectoryDataType(ModelType type) override; |
| 75 void ActivateNonBlockingDataType(ModelType type, | 75 void ActivateNonBlockingDataType(ModelType type, |
| 76 std::unique_ptr<ActivationContext>) override; | 76 std::unique_ptr<ActivationContext>) override; |
| 77 void DeactivateNonBlockingDataType(ModelType type) override; | 77 void DeactivateNonBlockingDataType(ModelType type) override; |
| 78 void EnableEncryptEverything() override; | 78 void EnableEncryptEverything() override; |
| 79 UserShare* GetUserShare() const override; | 79 UserShare* GetUserShare() const override; |
| 80 Status GetDetailedStatus() override; | 80 Status GetDetailedStatus() override; |
| 81 SyncCycleSnapshot GetLastCycleSnapshot() const override; | |
| 82 bool HasUnsyncedItems() const override; | 81 bool HasUnsyncedItems() const override; |
| 83 bool IsNigoriEnabled() const override; | 82 bool IsNigoriEnabled() const override; |
| 84 PassphraseType GetPassphraseType() const override; | 83 PassphraseType GetPassphraseType() const override; |
| 85 base::Time GetExplicitPassphraseTime() const override; | 84 base::Time GetExplicitPassphraseTime() const override; |
| 86 bool IsCryptographerReady(const BaseTransaction* trans) const override; | 85 bool IsCryptographerReady(const BaseTransaction* trans) const override; |
| 87 void GetModelSafeRoutingInfo(ModelSafeRoutingInfo* out) const override; | 86 void GetModelSafeRoutingInfo(ModelSafeRoutingInfo* out) const override; |
| 88 void FlushDirectory() const override; | 87 void FlushDirectory() const override; |
| 89 void RequestBufferedProtocolEventsAndEnableForwarding() override; | 88 void RequestBufferedProtocolEventsAndEnableForwarding() override; |
| 90 void DisableProtocolEventForwarding() override; | 89 void DisableProtocolEventForwarding() override; |
| 91 void EnableDirectoryTypeDebugInfoForwarding() override; | 90 void EnableDirectoryTypeDebugInfoForwarding() override; |
| (...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 282 // The state of the passphrase required to decrypt the bag of encryption keys | 281 // The state of the passphrase required to decrypt the bag of encryption keys |
| 283 // in the nigori node. Updated whenever a new nigori node arrives or the user | 282 // in the nigori node. Updated whenever a new nigori node arrives or the user |
| 284 // manually changes their passphrase state. Cached so we can synchronously | 283 // manually changes their passphrase state. Cached so we can synchronously |
| 285 // check it from the UI thread. | 284 // check it from the UI thread. |
| 286 PassphraseType cached_passphrase_type_ = PassphraseType::IMPLICIT_PASSPHRASE; | 285 PassphraseType cached_passphrase_type_ = PassphraseType::IMPLICIT_PASSPHRASE; |
| 287 | 286 |
| 288 // If an explicit passphrase is in use, the time at which the passphrase was | 287 // If an explicit passphrase is in use, the time at which the passphrase was |
| 289 // first set (if available). | 288 // first set (if available). |
| 290 base::Time cached_explicit_passphrase_time_; | 289 base::Time cached_explicit_passphrase_time_; |
| 291 | 290 |
| 292 // UI-thread cache of the last SyncCycleSnapshot received from syncapi. | |
| 293 SyncCycleSnapshot last_snapshot_; | |
| 294 | |
| 295 invalidation::InvalidationService* invalidator_; | 291 invalidation::InvalidationService* invalidator_; |
| 296 bool invalidation_handler_registered_ = false; | 292 bool invalidation_handler_registered_ = false; |
| 297 | 293 |
| 298 // Checks that we're on the same thread this was constructed on (UI thread). | 294 // Checks that we're on the same thread this was constructed on (UI thread). |
| 299 base::ThreadChecker thread_checker_; | 295 base::ThreadChecker thread_checker_; |
| 300 | 296 |
| 301 base::WeakPtrFactory<SyncBackendHostImpl> weak_ptr_factory_; | 297 base::WeakPtrFactory<SyncBackendHostImpl> weak_ptr_factory_; |
| 302 | 298 |
| 303 DISALLOW_COPY_AND_ASSIGN(SyncBackendHostImpl); | 299 DISALLOW_COPY_AND_ASSIGN(SyncBackendHostImpl); |
| 304 }; | 300 }; |
| 305 | 301 |
| 306 } // namespace syncer | 302 } // namespace syncer |
| 307 | 303 |
| 308 #endif // COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_HOST_IMPL_H_ | 304 #endif // COMPONENTS_SYNC_DRIVER_GLUE_SYNC_BACKEND_HOST_IMPL_H_ |
| OLD | NEW |