| OLD | NEW |
| 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 SYNC_INTERNAL_API_SYNC_MANAGER_H_ | 5 #ifndef SYNC_INTERNAL_API_SYNC_MANAGER_H_ |
| 6 #define SYNC_INTERNAL_API_SYNC_MANAGER_H_ | 6 #define SYNC_INTERNAL_API_SYNC_MANAGER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 170 // Cryptographer::Observer implementation. | 170 // Cryptographer::Observer implementation. |
| 171 virtual void OnEncryptedTypesChanged( | 171 virtual void OnEncryptedTypesChanged( |
| 172 ModelTypeSet encrypted_types, | 172 ModelTypeSet encrypted_types, |
| 173 bool encrypt_everything) OVERRIDE; | 173 bool encrypt_everything) OVERRIDE; |
| 174 | 174 |
| 175 // SyncNotifierObserver implementation. | 175 // SyncNotifierObserver implementation. |
| 176 virtual void OnNotificationsEnabled() OVERRIDE; | 176 virtual void OnNotificationsEnabled() OVERRIDE; |
| 177 virtual void OnNotificationsDisabled( | 177 virtual void OnNotificationsDisabled( |
| 178 NotificationsDisabledReason reason) OVERRIDE; | 178 NotificationsDisabledReason reason) OVERRIDE; |
| 179 virtual void OnIncomingNotification( | 179 virtual void OnIncomingNotification( |
| 180 const ObjectIdPayloadMap& id_payloads, | 180 const ObjectIdStateMap& id_state_map, |
| 181 IncomingNotificationSource source) OVERRIDE; | 181 IncomingNotificationSource source) OVERRIDE; |
| 182 | 182 |
| 183 // Called only by our NetworkChangeNotifier. | 183 // Called only by our NetworkChangeNotifier. |
| 184 virtual void OnIPAddressChanged() OVERRIDE; | 184 virtual void OnIPAddressChanged() OVERRIDE; |
| 185 | 185 |
| 186 const SyncScheduler* scheduler() const; | 186 const SyncScheduler* scheduler() const; |
| 187 | 187 |
| 188 private: | 188 private: |
| 189 friend class SyncManagerTest; | 189 friend class SyncManagerTest; |
| 190 FRIEND_TEST_ALL_PREFIXES(SyncManagerTest, NudgeDelayTest); | 190 FRIEND_TEST_ALL_PREFIXES(SyncManagerTest, NudgeDelayTest); |
| (...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 287 void FinishSetPassphrase( | 287 void FinishSetPassphrase( |
| 288 bool success, | 288 bool success, |
| 289 const std::string& bootstrap_token, | 289 const std::string& bootstrap_token, |
| 290 bool is_explicit, | 290 bool is_explicit, |
| 291 WriteTransaction* trans, | 291 WriteTransaction* trans, |
| 292 WriteNode* nigori_node); | 292 WriteNode* nigori_node); |
| 293 | 293 |
| 294 // Called for every notification. This updates the notification statistics | 294 // Called for every notification. This updates the notification statistics |
| 295 // to be displayed in about:sync. | 295 // to be displayed in about:sync. |
| 296 void UpdateNotificationInfo( | 296 void UpdateNotificationInfo( |
| 297 const ModelTypePayloadMap& type_payloads); | 297 const ModelTypeStateMap& type_state_map); |
| 298 | 298 |
| 299 // Checks for server reachabilty and requests a nudge. | 299 // Checks for server reachabilty and requests a nudge. |
| 300 void OnIPAddressChangedImpl(); | 300 void OnIPAddressChangedImpl(); |
| 301 | 301 |
| 302 // Helper function used only by the constructor. | 302 // Helper function used only by the constructor. |
| 303 void BindJsMessageHandler( | 303 void BindJsMessageHandler( |
| 304 const std::string& name, UnboundJsMessageHandler unbound_message_handler); | 304 const std::string& name, UnboundJsMessageHandler unbound_message_handler); |
| 305 | 305 |
| 306 // Helper function used by OnNotifications{Enabled,Disabled}(). | 306 // Helper function used by OnNotifications{Enabled,Disabled}(). |
| 307 void OnNotificationStateChange(NotificationsDisabledReason reason); | 307 void OnNotificationStateChange(NotificationsDisabledReason reason); |
| (...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 419 // conflict resolver) updated the nigori's encryption keys in this chrome | 419 // conflict resolver) updated the nigori's encryption keys in this chrome |
| 420 // instantiation. | 420 // instantiation. |
| 421 int nigori_overwrite_count_; | 421 int nigori_overwrite_count_; |
| 422 | 422 |
| 423 DISALLOW_COPY_AND_ASSIGN(SyncManagerImpl); | 423 DISALLOW_COPY_AND_ASSIGN(SyncManagerImpl); |
| 424 }; | 424 }; |
| 425 | 425 |
| 426 } // namespace syncer | 426 } // namespace syncer |
| 427 | 427 |
| 428 #endif // SYNC_INTERNAL_API_SYNC_MANAGER_H_ | 428 #endif // SYNC_INTERNAL_API_SYNC_MANAGER_H_ |
| OLD | NEW |