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

Side by Side Diff: chrome/browser/sync/engine/build_and_process_conflict_sets_command.h

Issue 386030: Relieve SyncerSession,SyncCycleState, SyncProcessState, SyncerSession, Syncer... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 1 month 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 (c) 2006-2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2009 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_ENGINE_BUILD_AND_PROCESS_CONFLICT_SETS_COMMAND_H_ 5 #ifndef CHROME_BROWSER_SYNC_ENGINE_BUILD_AND_PROCESS_CONFLICT_SETS_COMMAND_H_
6 #define CHROME_BROWSER_SYNC_ENGINE_BUILD_AND_PROCESS_CONFLICT_SETS_COMMAND_H_ 6 #define CHROME_BROWSER_SYNC_ENGINE_BUILD_AND_PROCESS_CONFLICT_SETS_COMMAND_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
11 #include "chrome/browser/sync/engine/model_changing_syncer_command.h" 11 #include "chrome/browser/sync/engine/model_changing_syncer_command.h"
12 12
13 namespace syncable { 13 namespace syncable {
14 class BaseTransaction; 14 class BaseTransaction;
15 class Entry; 15 class Entry;
16 class Id; 16 class Id;
17 class MutableEntry; 17 class MutableEntry;
18 class WriteTransaction; 18 class WriteTransaction;
19 } // namespace syncable 19 } // namespace syncable
20 20
21 namespace browser_sync { 21 namespace browser_sync {
22 22
23 class ConflictResolutionView; 23 class ConflictResolver;
24 class SyncerSession; 24
25 namespace sessions {
26 class ConflictProgress;
27 class StatusController;
28 }
25 29
26 class BuildAndProcessConflictSetsCommand : public ModelChangingSyncerCommand { 30 class BuildAndProcessConflictSetsCommand : public ModelChangingSyncerCommand {
27 public: 31 public:
28 BuildAndProcessConflictSetsCommand(); 32 BuildAndProcessConflictSetsCommand();
29 virtual ~BuildAndProcessConflictSetsCommand(); 33 virtual ~BuildAndProcessConflictSetsCommand();
30 34
31 virtual void ModelChangingExecuteImpl(SyncerSession* session); 35 // ModelChangingSyncerCommand implementation.
36 virtual void ModelChangingExecuteImpl(sessions::SyncSession* session);
32 37
33 private: 38 private:
34 bool BuildAndProcessConflictSets(SyncerSession* session); 39 bool BuildAndProcessConflictSets(sessions::SyncSession* session);
35 40
36 bool ProcessSingleDirectionConflictSets( 41 bool ProcessSingleDirectionConflictSets(
37 syncable::WriteTransaction* trans, SyncerSession* const session); 42 syncable::WriteTransaction* trans, ConflictResolver* resolver,
43 sessions::StatusController* status);
38 bool ApplyUpdatesTransactionally( 44 bool ApplyUpdatesTransactionally(
39 syncable::WriteTransaction* trans, 45 syncable::WriteTransaction* trans,
40 const std::vector<syncable::Id>* const update_set, 46 const std::vector<syncable::Id>* const update_set,
41 SyncerSession* const session); 47 ConflictResolver* resolver,
48 sessions::StatusController* status);
42 void BuildConflictSets(syncable::BaseTransaction* trans, 49 void BuildConflictSets(syncable::BaseTransaction* trans,
43 ConflictResolutionView* view); 50 sessions::ConflictProgress* conflict_progress);
44 51
45 void MergeSetsForNameClash(syncable::BaseTransaction* trans, 52 void MergeSetsForNameClash(syncable::BaseTransaction* trans,
46 syncable::Entry* entry, 53 syncable::Entry* entry,
47 ConflictResolutionView* view); 54 sessions::ConflictProgress* conflict_progress);
48 void MergeSetsForIntroducedLoops(syncable::BaseTransaction* trans, 55 void MergeSetsForIntroducedLoops(syncable::BaseTransaction* trans,
49 syncable::Entry* entry, 56 syncable::Entry* entry,
50 ConflictResolutionView* view); 57 sessions::ConflictProgress* conflict_progress);
51 void MergeSetsForNonEmptyDirectories(syncable::BaseTransaction* trans, 58 void MergeSetsForNonEmptyDirectories(syncable::BaseTransaction* trans,
52 syncable::Entry* entry, 59 syncable::Entry* entry,
53 ConflictResolutionView* view); 60 sessions::ConflictProgress* conflict_progress);
54 void MergeSetsForPositionUpdate(syncable::BaseTransaction* trans, 61 void MergeSetsForPositionUpdate(syncable::BaseTransaction* trans,
55 syncable::Entry* entry, 62 syncable::Entry* entry,
56 ConflictResolutionView* view); 63 sessions::ConflictProgress* conflict_progress);
57 64
58 DISALLOW_COPY_AND_ASSIGN(BuildAndProcessConflictSetsCommand); 65 DISALLOW_COPY_AND_ASSIGN(BuildAndProcessConflictSetsCommand);
59 }; 66 };
60 67
61 } // namespace browser_sync 68 } // namespace browser_sync
62 69
63 #endif // CHROME_BROWSER_SYNC_ENGINE_BUILD_AND_PROCESS_CONFLICT_SETS_COMMAND_H_ 70 #endif // CHROME_BROWSER_SYNC_ENGINE_BUILD_AND_PROCESS_CONFLICT_SETS_COMMAND_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698