| 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 SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_ | 5 #ifndef SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_ |
| 6 #define SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_ | 6 #define SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <memory> | 10 #include <memory> |
| (...skipping 19 matching lines...) Expand all Loading... |
| 30 #include "sync/internal_api/public/http_post_provider_factory.h" | 30 #include "sync/internal_api/public/http_post_provider_factory.h" |
| 31 #include "sync/internal_api/public/internal_components_factory.h" | 31 #include "sync/internal_api/public/internal_components_factory.h" |
| 32 #include "sync/internal_api/public/model_type_connector.h" | 32 #include "sync/internal_api/public/model_type_connector.h" |
| 33 #include "sync/internal_api/public/shutdown_reason.h" | 33 #include "sync/internal_api/public/shutdown_reason.h" |
| 34 #include "sync/internal_api/public/sync_encryption_handler.h" | 34 #include "sync/internal_api/public/sync_encryption_handler.h" |
| 35 #include "sync/internal_api/public/util/weak_handle.h" | 35 #include "sync/internal_api/public/util/weak_handle.h" |
| 36 #include "sync/protocol/sync_protocol_error.h" | 36 #include "sync/protocol/sync_protocol_error.h" |
| 37 | 37 |
| 38 class GURL; | 38 class GURL; |
| 39 | 39 |
| 40 namespace base { |
| 41 namespace trace_event { |
| 42 class ProcessMemoryDump; |
| 43 } |
| 44 } |
| 45 |
| 40 namespace sync_pb { | 46 namespace sync_pb { |
| 41 class EncryptedData; | 47 class EncryptedData; |
| 42 } // namespace sync_pb | 48 } // namespace sync_pb |
| 43 | 49 |
| 44 namespace syncer { | 50 namespace syncer { |
| 45 | 51 |
| 46 class BaseTransaction; | 52 class BaseTransaction; |
| 47 class CancelationSignal; | 53 class CancelationSignal; |
| 48 class DataTypeDebugInfoListener; | 54 class DataTypeDebugInfoListener; |
| 49 class Encryptor; | 55 class Encryptor; |
| (...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 337 virtual void AddObserver(Observer* observer) = 0; | 343 virtual void AddObserver(Observer* observer) = 0; |
| 338 | 344 |
| 339 // Remove the given observer. Make sure to call this if the | 345 // Remove the given observer. Make sure to call this if the |
| 340 // Observer is being destroyed so the SyncManager doesn't | 346 // Observer is being destroyed so the SyncManager doesn't |
| 341 // potentially dereference garbage. | 347 // potentially dereference garbage. |
| 342 virtual void RemoveObserver(Observer* observer) = 0; | 348 virtual void RemoveObserver(Observer* observer) = 0; |
| 343 | 349 |
| 344 // Status-related getter. May be called on any thread. | 350 // Status-related getter. May be called on any thread. |
| 345 virtual SyncStatus GetDetailedStatus() const = 0; | 351 virtual SyncStatus GetDetailedStatus() const = 0; |
| 346 | 352 |
| 353 // Adds memory usage statistics to |pmd| for chrome://tracing. |
| 354 virtual void OnMemoryDump(base::trace_event::ProcessMemoryDump* pmd) = 0; |
| 355 |
| 347 // Call periodically from a database-safe thread to persist recent changes | 356 // Call periodically from a database-safe thread to persist recent changes |
| 348 // to the syncapi model. | 357 // to the syncapi model. |
| 349 virtual void SaveChanges() = 0; | 358 virtual void SaveChanges() = 0; |
| 350 | 359 |
| 351 // Issue a final SaveChanges, and close sqlite handles. | 360 // Issue a final SaveChanges, and close sqlite handles. |
| 352 virtual void ShutdownOnSyncThread(ShutdownReason reason) = 0; | 361 virtual void ShutdownOnSyncThread(ShutdownReason reason) = 0; |
| 353 | 362 |
| 354 // May be called from any thread. | 363 // May be called from any thread. |
| 355 virtual UserShare* GetUserShare() = 0; | 364 virtual UserShare* GetUserShare() = 0; |
| 356 | 365 |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 404 | 413 |
| 405 // Updates Sync's tracking of whether the cookie jar has a mismatch with the | 414 // Updates Sync's tracking of whether the cookie jar has a mismatch with the |
| 406 // chrome account. See ClientConfigParams proto message for more info. | 415 // chrome account. See ClientConfigParams proto message for more info. |
| 407 // Note: this does not trigger a sync cycle. It just updates the sync context. | 416 // Note: this does not trigger a sync cycle. It just updates the sync context. |
| 408 virtual void OnCookieJarChanged(bool account_mismatch, bool empty_jar) = 0; | 417 virtual void OnCookieJarChanged(bool account_mismatch, bool empty_jar) = 0; |
| 409 }; | 418 }; |
| 410 | 419 |
| 411 } // namespace syncer | 420 } // namespace syncer |
| 412 | 421 |
| 413 #endif // SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_ | 422 #endif // SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_ |
| OLD | NEW |