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

Side by Side Diff: chrome/browser/sync/glue/sync_backend_host_impl.h

Issue 1253743003: [Sync] Update SyncBackendHost to forward ClearServerData to SyncManager (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@clearserverdatacommand
Patch Set: Remove unused callback variable Created 5 years, 4 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
OLDNEW
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 CHROME_BROWSER_SYNC_GLUE_SYNC_BACKEND_HOST_IMPL_H_ 5 #ifndef CHROME_BROWSER_SYNC_GLUE_SYNC_BACKEND_HOST_IMPL_H_
6 #define CHROME_BROWSER_SYNC_GLUE_SYNC_BACKEND_HOST_IMPL_H_ 6 #define CHROME_BROWSER_SYNC_GLUE_SYNC_BACKEND_HOST_IMPL_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 void RequestBufferedProtocolEventsAndEnableForwarding() override; 128 void RequestBufferedProtocolEventsAndEnableForwarding() override;
129 void DisableProtocolEventForwarding() override; 129 void DisableProtocolEventForwarding() override;
130 void EnableDirectoryTypeDebugInfoForwarding() override; 130 void EnableDirectoryTypeDebugInfoForwarding() override;
131 void DisableDirectoryTypeDebugInfoForwarding() override; 131 void DisableDirectoryTypeDebugInfoForwarding() override;
132 void GetAllNodesForTypes( 132 void GetAllNodesForTypes(
133 syncer::ModelTypeSet types, 133 syncer::ModelTypeSet types,
134 base::Callback<void(const std::vector<syncer::ModelType>&, 134 base::Callback<void(const std::vector<syncer::ModelType>&,
135 ScopedVector<base::ListValue>)> type) override; 135 ScopedVector<base::ListValue>)> type) override;
136 base::MessageLoop* GetSyncLoopForTesting() override; 136 base::MessageLoop* GetSyncLoopForTesting() override;
137 void RefreshTypesForTest(syncer::ModelTypeSet types) override; 137 void RefreshTypesForTest(syncer::ModelTypeSet types) override;
138 void ClearServerData(
139 const syncer::SyncManager::ClearServerDataCallback& callback) override;
138 140
139 protected: 141 protected:
140 // The types and functions below are protected so that test 142 // The types and functions below are protected so that test
141 // subclasses can use them. 143 // subclasses can use them.
142 144
143 // Allows tests to perform alternate core initialization work. 145 // Allows tests to perform alternate core initialization work.
144 virtual void InitCore(scoped_ptr<DoInitializeOptions> options); 146 virtual void InitCore(scoped_ptr<DoInitializeOptions> options);
145 147
146 // Request the syncer to reconfigure with the specfied params. 148 // Request the syncer to reconfigure with the specfied params.
147 // Virtual for testing. 149 // Virtual for testing.
(...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after
294 void Observe(int type, 296 void Observe(int type,
295 const content::NotificationSource& source, 297 const content::NotificationSource& source,
296 const content::NotificationDetails& details) override; 298 const content::NotificationDetails& details) override;
297 299
298 // InvalidationHandler implementation. 300 // InvalidationHandler implementation.
299 void OnInvalidatorStateChange(syncer::InvalidatorState state) override; 301 void OnInvalidatorStateChange(syncer::InvalidatorState state) override;
300 void OnIncomingInvalidation( 302 void OnIncomingInvalidation(
301 const syncer::ObjectIdInvalidationMap& invalidation_map) override; 303 const syncer::ObjectIdInvalidationMap& invalidation_map) override;
302 std::string GetOwnerName() const override; 304 std::string GetOwnerName() const override;
303 305
306 void ClearServerDataDoneOnFrontendLoop(
307 const syncer::SyncManager::ClearServerDataCallback& frontend_callback);
308
304 content::NotificationRegistrar notification_registrar_; 309 content::NotificationRegistrar notification_registrar_;
305 310
306 // A reference to the MessageLoop used to construct |this|, so we know how 311 // A reference to the MessageLoop used to construct |this|, so we know how
307 // to safely talk back to the SyncFrontend. 312 // to safely talk back to the SyncFrontend.
308 base::MessageLoop* const frontend_loop_; 313 base::MessageLoop* const frontend_loop_;
309 314
310 Profile* const profile_; 315 Profile* const profile_;
311 316
312 // Name used for debugging (set from profile_->GetDebugName()). 317 // Name used for debugging (set from profile_->GetDebugName()).
313 const std::string name_; 318 const std::string name_;
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
358 bool invalidation_handler_registered_; 363 bool invalidation_handler_registered_;
359 364
360 base::WeakPtrFactory<SyncBackendHostImpl> weak_ptr_factory_; 365 base::WeakPtrFactory<SyncBackendHostImpl> weak_ptr_factory_;
361 366
362 DISALLOW_COPY_AND_ASSIGN(SyncBackendHostImpl); 367 DISALLOW_COPY_AND_ASSIGN(SyncBackendHostImpl);
363 }; 368 };
364 369
365 } // namespace browser_sync 370 } // namespace browser_sync
366 371
367 #endif // CHROME_BROWSER_SYNC_GLUE_SYNC_BACKEND_HOST_IMPL_H_ 372 #endif // CHROME_BROWSER_SYNC_GLUE_SYNC_BACKEND_HOST_IMPL_H_
OLDNEW
« no previous file with comments | « chrome/browser/sync/glue/sync_backend_host_core.cc ('k') | chrome/browser/sync/glue/sync_backend_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698