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

Side by Side Diff: chrome/browser/sync_file_system/drive_backend/sync_engine.h

Issue 185563011: [SyncFS] Change RemoteFileSyncService interface to accept per-app conflict resolution policy (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 9 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 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_FILE_SYSTEM_DRIVE_BACKEND_SYNC_ENGINE_H_ 5 #ifndef CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_BACKEND_SYNC_ENGINE_H_
6 #define CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_BACKEND_SYNC_ENGINE_H_ 6 #define CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_BACKEND_SYNC_ENGINE_H_
7 7
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "base/memory/weak_ptr.h" 9 #include "base/memory/weak_ptr.h"
10 #include "base/observer_list.h" 10 #include "base/observer_list.h"
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 virtual void ProcessRemoteChange(const SyncFileCallback& callback) OVERRIDE; 78 virtual void ProcessRemoteChange(const SyncFileCallback& callback) OVERRIDE;
79 virtual void SetRemoteChangeProcessor( 79 virtual void SetRemoteChangeProcessor(
80 RemoteChangeProcessor* processor) OVERRIDE; 80 RemoteChangeProcessor* processor) OVERRIDE;
81 virtual LocalChangeProcessor* GetLocalChangeProcessor() OVERRIDE; 81 virtual LocalChangeProcessor* GetLocalChangeProcessor() OVERRIDE;
82 virtual bool IsConflicting(const fileapi::FileSystemURL& url) OVERRIDE; 82 virtual bool IsConflicting(const fileapi::FileSystemURL& url) OVERRIDE;
83 virtual RemoteServiceState GetCurrentState() const OVERRIDE; 83 virtual RemoteServiceState GetCurrentState() const OVERRIDE;
84 virtual void GetOriginStatusMap(OriginStatusMap* status_map) OVERRIDE; 84 virtual void GetOriginStatusMap(OriginStatusMap* status_map) OVERRIDE;
85 virtual scoped_ptr<base::ListValue> DumpFiles(const GURL& origin) OVERRIDE; 85 virtual scoped_ptr<base::ListValue> DumpFiles(const GURL& origin) OVERRIDE;
86 virtual scoped_ptr<base::ListValue> DumpDatabase() OVERRIDE; 86 virtual scoped_ptr<base::ListValue> DumpDatabase() OVERRIDE;
87 virtual void SetSyncEnabled(bool enabled) OVERRIDE; 87 virtual void SetSyncEnabled(bool enabled) OVERRIDE;
88 virtual SyncStatusCode SetDefaultConflictResolutionPolicy(
89 ConflictResolutionPolicy policy) OVERRIDE;
88 virtual SyncStatusCode SetConflictResolutionPolicy( 90 virtual SyncStatusCode SetConflictResolutionPolicy(
91 const GURL& origin,
89 ConflictResolutionPolicy policy) OVERRIDE; 92 ConflictResolutionPolicy policy) OVERRIDE;
90 virtual ConflictResolutionPolicy GetConflictResolutionPolicy() const OVERRIDE; 93 virtual ConflictResolutionPolicy GetDefaultConflictResolutionPolicy()
94 const OVERRIDE;
95 virtual ConflictResolutionPolicy GetConflictResolutionPolicy(
96 const GURL& origin) const OVERRIDE;
91 virtual void GetRemoteVersions( 97 virtual void GetRemoteVersions(
92 const fileapi::FileSystemURL& url, 98 const fileapi::FileSystemURL& url,
93 const RemoteVersionsCallback& callback) OVERRIDE; 99 const RemoteVersionsCallback& callback) OVERRIDE;
94 virtual void DownloadRemoteVersion( 100 virtual void DownloadRemoteVersion(
95 const fileapi::FileSystemURL& url, 101 const fileapi::FileSystemURL& url,
96 const std::string& version_id, 102 const std::string& version_id,
97 const DownloadVersionCallback& callback) OVERRIDE; 103 const DownloadVersionCallback& callback) OVERRIDE;
98 virtual void PromoteDemotedChanges() OVERRIDE; 104 virtual void PromoteDemotedChanges() OVERRIDE;
99 105
100 // LocalChangeProcessor overrides. 106 // LocalChangeProcessor overrides.
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
190 RemoteChangeProcessor* remote_change_processor_; 196 RemoteChangeProcessor* remote_change_processor_;
191 197
192 RemoteServiceState service_state_; 198 RemoteServiceState service_state_;
193 199
194 bool should_check_conflict_; 200 bool should_check_conflict_;
195 bool should_check_remote_change_; 201 bool should_check_remote_change_;
196 bool listing_remote_changes_; 202 bool listing_remote_changes_;
197 base::TimeTicks time_to_check_changes_; 203 base::TimeTicks time_to_check_changes_;
198 204
199 bool sync_enabled_; 205 bool sync_enabled_;
200 ConflictResolutionPolicy conflict_resolution_policy_; 206 ConflictResolutionPolicy default_conflict_resolution_policy_;
201 bool network_available_; 207 bool network_available_;
202 208
203 scoped_ptr<SyncTaskManager> task_manager_; 209 scoped_ptr<SyncTaskManager> task_manager_;
204 210
205 base::WeakPtrFactory<SyncEngine> weak_ptr_factory_; 211 base::WeakPtrFactory<SyncEngine> weak_ptr_factory_;
206 212
207 DISALLOW_COPY_AND_ASSIGN(SyncEngine); 213 DISALLOW_COPY_AND_ASSIGN(SyncEngine);
208 }; 214 };
209 215
210 } // namespace drive_backend 216 } // namespace drive_backend
211 } // namespace sync_file_system 217 } // namespace sync_file_system
212 218
213 #endif // CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_BACKEND_SYNC_ENGINE_H_ 219 #endif // CHROME_BROWSER_SYNC_FILE_SYSTEM_DRIVE_BACKEND_SYNC_ENGINE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698