Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(37)

Side by Side Diff: sync/internal_api/sync_manager_impl.h

Issue 212603007: sync: Buffer Protocol Events for about:sync page (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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_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
11 #include "net/base/network_change_notifier.h" 11 #include "net/base/network_change_notifier.h"
12 #include "sync/base/sync_export.h" 12 #include "sync/base/sync_export.h"
13 #include "sync/engine/all_status.h" 13 #include "sync/engine/all_status.h"
14 #include "sync/engine/net/server_connection_manager.h" 14 #include "sync/engine/net/server_connection_manager.h"
15 #include "sync/engine/sync_engine_event_listener.h" 15 #include "sync/engine/sync_engine_event_listener.h"
16 #include "sync/engine/traffic_recorder.h" 16 #include "sync/engine/traffic_recorder.h"
17 #include "sync/internal_api/change_reorder_buffer.h" 17 #include "sync/internal_api/change_reorder_buffer.h"
18 #include "sync/internal_api/debug_info_event_listener.h" 18 #include "sync/internal_api/debug_info_event_listener.h"
19 #include "sync/internal_api/js_mutation_event_observer.h" 19 #include "sync/internal_api/js_mutation_event_observer.h"
20 #include "sync/internal_api/js_sync_encryption_handler_observer.h" 20 #include "sync/internal_api/js_sync_encryption_handler_observer.h"
21 #include "sync/internal_api/js_sync_manager_observer.h" 21 #include "sync/internal_api/js_sync_manager_observer.h"
22 #include "sync/internal_api/protocol_event_buffer.h"
22 #include "sync/internal_api/public/sync_manager.h" 23 #include "sync/internal_api/public/sync_manager.h"
23 #include "sync/internal_api/public/user_share.h" 24 #include "sync/internal_api/public/user_share.h"
24 #include "sync/internal_api/sync_encryption_handler_impl.h" 25 #include "sync/internal_api/sync_encryption_handler_impl.h"
25 #include "sync/js/js_backend.h" 26 #include "sync/js/js_backend.h"
26 #include "sync/notifier/invalidation_handler.h" 27 #include "sync/notifier/invalidation_handler.h"
27 #include "sync/notifier/invalidator_state.h" 28 #include "sync/notifier/invalidator_state.h"
28 #include "sync/syncable/directory_change_delegate.h" 29 #include "sync/syncable/directory_change_delegate.h"
29 #include "sync/util/cryptographer.h" 30 #include "sync/util/cryptographer.h"
30 #include "sync/util/time.h" 31 #include "sync/util/time.h"
31 32
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
108 virtual void RemoveObserver(SyncManager::Observer* observer) OVERRIDE; 109 virtual void RemoveObserver(SyncManager::Observer* observer) OVERRIDE;
109 virtual SyncStatus GetDetailedStatus() const OVERRIDE; 110 virtual SyncStatus GetDetailedStatus() const OVERRIDE;
110 virtual void SaveChanges() OVERRIDE; 111 virtual void SaveChanges() OVERRIDE;
111 virtual void ShutdownOnSyncThread() OVERRIDE; 112 virtual void ShutdownOnSyncThread() OVERRIDE;
112 virtual UserShare* GetUserShare() OVERRIDE; 113 virtual UserShare* GetUserShare() OVERRIDE;
113 virtual syncer::SyncCore* GetSyncCore() OVERRIDE; 114 virtual syncer::SyncCore* GetSyncCore() OVERRIDE;
114 virtual const std::string cache_guid() OVERRIDE; 115 virtual const std::string cache_guid() OVERRIDE;
115 virtual bool ReceivedExperiment(Experiments* experiments) OVERRIDE; 116 virtual bool ReceivedExperiment(Experiments* experiments) OVERRIDE;
116 virtual bool HasUnsyncedItems() OVERRIDE; 117 virtual bool HasUnsyncedItems() OVERRIDE;
117 virtual SyncEncryptionHandler* GetEncryptionHandler() OVERRIDE; 118 virtual SyncEncryptionHandler* GetEncryptionHandler() OVERRIDE;
119 virtual ScopedVector<syncer::ProtocolEvent>
120 GetBufferedProtocolEvents() OVERRIDE;
118 121
119 // SyncEncryptionHandler::Observer implementation. 122 // SyncEncryptionHandler::Observer implementation.
120 virtual void OnPassphraseRequired( 123 virtual void OnPassphraseRequired(
121 PassphraseRequiredReason reason, 124 PassphraseRequiredReason reason,
122 const sync_pb::EncryptedData& pending_keys) OVERRIDE; 125 const sync_pb::EncryptedData& pending_keys) OVERRIDE;
123 virtual void OnPassphraseAccepted() OVERRIDE; 126 virtual void OnPassphraseAccepted() OVERRIDE;
124 virtual void OnBootstrapTokenUpdated( 127 virtual void OnBootstrapTokenUpdated(
125 const std::string& bootstrap_token, 128 const std::string& bootstrap_token,
126 BootstrapTokenType type) OVERRIDE; 129 BootstrapTokenType type) OVERRIDE;
127 virtual void OnEncryptedTypesChanged( 130 virtual void OnEncryptedTypesChanged(
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after
351 354
352 // These are for interacting with chrome://sync-internals. 355 // These are for interacting with chrome://sync-internals.
353 JsMessageHandlerMap js_message_handlers_; 356 JsMessageHandlerMap js_message_handlers_;
354 JsSyncManagerObserver js_sync_manager_observer_; 357 JsSyncManagerObserver js_sync_manager_observer_;
355 JsMutationEventObserver js_mutation_event_observer_; 358 JsMutationEventObserver js_mutation_event_observer_;
356 JsSyncEncryptionHandlerObserver js_sync_encryption_handler_observer_; 359 JsSyncEncryptionHandlerObserver js_sync_encryption_handler_observer_;
357 360
358 // This is for keeping track of client events to send to the server. 361 // This is for keeping track of client events to send to the server.
359 DebugInfoEventListener debug_info_event_listener_; 362 DebugInfoEventListener debug_info_event_listener_;
360 363
364 ProtocolEventBuffer protocol_event_buffer_;
361 TrafficRecorder traffic_recorder_; 365 TrafficRecorder traffic_recorder_;
362 366
363 Encryptor* encryptor_; 367 Encryptor* encryptor_;
364 scoped_ptr<UnrecoverableErrorHandler> unrecoverable_error_handler_; 368 scoped_ptr<UnrecoverableErrorHandler> unrecoverable_error_handler_;
365 ReportUnrecoverableErrorFunction report_unrecoverable_error_function_; 369 ReportUnrecoverableErrorFunction report_unrecoverable_error_function_;
366 370
367 // Sync's encryption handler. It tracks the set of encrypted types, manages 371 // Sync's encryption handler. It tracks the set of encrypted types, manages
368 // changing passphrases, and in general handles sync-specific interactions 372 // changing passphrases, and in general handles sync-specific interactions
369 // with the cryptographer. 373 // with the cryptographer.
370 scoped_ptr<SyncEncryptionHandlerImpl> sync_encryption_handler_; 374 scoped_ptr<SyncEncryptionHandlerImpl> sync_encryption_handler_;
371 375
372 base::WeakPtrFactory<SyncManagerImpl> weak_ptr_factory_; 376 base::WeakPtrFactory<SyncManagerImpl> weak_ptr_factory_;
373 377
374 DISALLOW_COPY_AND_ASSIGN(SyncManagerImpl); 378 DISALLOW_COPY_AND_ASSIGN(SyncManagerImpl);
375 }; 379 };
376 380
377 } // namespace syncer 381 } // namespace syncer
378 382
379 #endif // SYNC_INTERNAL_API_SYNC_MANAGER_H_ 383 #endif // SYNC_INTERNAL_API_SYNC_MANAGER_H_
OLDNEW
« no previous file with comments | « sync/internal_api/public/test/fake_sync_manager.h ('k') | sync/internal_api/sync_manager_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698