Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 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 | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef CHROME_BROWSER_SYNC_GLUE_NIGORI_CHANGE_PROCESSOR_H_ | |
| 6 #define CHROME_BROWSER_SYNC_GLUE_NIGORI_CHANGE_PROCESSOR_H_ | |
| 7 | |
| 8 #include "sync/internal_api/public/base/model_type.h" | |
| 9 | |
| 10 namespace syncer { | |
| 11 struct Experiments; | |
| 12 class SyncEncryptionHandler; | |
| 13 struct UserShare; | |
| 14 } | |
| 15 | |
| 16 namespace browser_sync { | |
| 17 | |
| 18 // A change processor for handling updates to the nigori node. Interacts | |
| 19 // directly with the SyncEncryptionHandler. | |
| 20 // TODO(zea): implement the ChangeProcessor interface. | |
| 21 class NigoriChangeProcessor { | |
| 22 public: | |
| 23 NigoriChangeProcessor( | |
| 24 syncer::SyncEncryptionHandler* encryption_handler); | |
| 25 virtual ~NigoriChangeProcessor(); | |
| 26 | |
| 27 // Merge local state and nigori node state. | |
| 28 void AssociateModels(syncer::UserShare* user_share); | |
| 29 // Disconnect the change processor from sync. | |
| 30 void DisassociateModels(); | |
| 31 | |
| 32 // Reads the nigori node to determine if any experimental features should | |
| 33 // be enabled. | |
| 34 // Note: opens a transaction. May be called on any thread. | |
| 35 bool ReceivedExperiments(syncer::Experiments* experiments); | |
| 36 | |
| 37 // TODO(zea): ChangeProcessor implementation. | |
|
tim (not reviewing)
2012/08/12 23:31:20
Why is this called ChangeProcessor if it does most
Nicolas Zea
2012/08/13 22:56:38
Removed this file.
| |
| 38 private: | |
| 39 DISALLOW_COPY_AND_ASSIGN(NigoriChangeProcessor); | |
| 40 | |
| 41 // This profile's user share. Used to create sync transactions. | |
| 42 syncer::UserShare* user_share_; | |
| 43 | |
| 44 // Sync's encryption handler. | |
| 45 syncer::SyncEncryptionHandler* encryption_handler_; | |
| 46 }; | |
| 47 | |
| 48 } // namespace browser_sync | |
| 49 | |
| 50 #endif // CHROME_BROWSER_SYNC_GLUE_NIGORI_CHANGE_PROCESSOR_H_ | |
| OLD | NEW |