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

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

Issue 8510079: sync: Remove ModelNeutralExecuteImpl() (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix bug that caused integration test failures Created 9 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_PROCESS_COMMIT_RESPONSE_COMMAND_H_ 5 #ifndef CHROME_BROWSER_SYNC_ENGINE_PROCESS_COMMIT_RESPONSE_COMMAND_H_
6 #define CHROME_BROWSER_SYNC_ENGINE_PROCESS_COMMIT_RESPONSE_COMMAND_H_ 6 #define CHROME_BROWSER_SYNC_ENGINE_PROCESS_COMMIT_RESPONSE_COMMAND_H_
7 #pragma once 7 #pragma once
8 8
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
11 11
12 #include "base/basictypes.h" 12 #include "base/basictypes.h"
13 #include "chrome/browser/sync/engine/model_changing_syncer_command.h" 13 #include "chrome/browser/sync/engine/model_changing_syncer_command.h"
14 #include "chrome/browser/sync/engine/syncproto.h" 14 #include "chrome/browser/sync/engine/syncproto.h"
15 15
16 namespace syncable { 16 namespace syncable {
17 class Id; 17 class Id;
18 class WriteTransaction; 18 class WriteTransaction;
19 class MutableEntry; 19 class MutableEntry;
20 } 20 }
21 21
22 namespace browser_sync { 22 namespace browser_sync {
23 23
24 class ProcessCommitResponseCommand : public ModelChangingSyncerCommand { 24 class ProcessCommitResponseCommand : public ModelChangingSyncerCommand {
25 public: 25 public:
26 26
27 ProcessCommitResponseCommand(); 27 ProcessCommitResponseCommand();
28 virtual ~ProcessCommitResponseCommand(); 28 virtual ~ProcessCommitResponseCommand();
29 29
30 // Override part of ModelChangingSyncerCommand's SyncerCommand implementation
31 virtual void ExecuteImpl(sessions::SyncSession*);
32
30 // ModelChangingSyncerCommand implementation. 33 // ModelChangingSyncerCommand implementation.
31 virtual bool ModelNeutralExecuteImpl(sessions::SyncSession* session);
32 virtual void ModelChangingExecuteImpl(sessions::SyncSession* session); 34 virtual void ModelChangingExecuteImpl(sessions::SyncSession* session);
33 35
34 private: 36 private:
37 // Returns true if these updates should not be processed.
38 bool ModelNeutralShouldExitEarly(sessions::SyncSession* session);
39
35 CommitResponse::ResponseType ProcessSingleCommitResponse( 40 CommitResponse::ResponseType ProcessSingleCommitResponse(
36 syncable::WriteTransaction* trans, 41 syncable::WriteTransaction* trans,
37 const sync_pb::CommitResponse_EntryResponse& pb_commit_response, 42 const sync_pb::CommitResponse_EntryResponse& pb_commit_response,
38 const sync_pb::SyncEntity& pb_committed_entry, 43 const sync_pb::SyncEntity& pb_committed_entry,
39 const syncable::Id& pre_commit_id, 44 const syncable::Id& pre_commit_id,
40 std::set<syncable::Id>* conflicting_new_directory_ids, 45 std::set<syncable::Id>* conflicting_new_directory_ids,
41 std::set<syncable::Id>* deleted_folders); 46 std::set<syncable::Id>* deleted_folders);
42 47
43 // Actually does the work of execute. 48 // Actually does the work of execute.
44 void ProcessCommitResponse(sessions::SyncSession* session); 49 void ProcessCommitResponse(sessions::SyncSession* session);
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 const std::string& GetResultingPostCommitName( 91 const std::string& GetResultingPostCommitName(
87 const sync_pb::SyncEntity& committed_entry, 92 const sync_pb::SyncEntity& committed_entry,
88 const CommitResponse_EntryResponse& entry_response); 93 const CommitResponse_EntryResponse& entry_response);
89 94
90 DISALLOW_COPY_AND_ASSIGN(ProcessCommitResponseCommand); 95 DISALLOW_COPY_AND_ASSIGN(ProcessCommitResponseCommand);
91 }; 96 };
92 97
93 } // namespace browser_sync 98 } // namespace browser_sync
94 99
95 #endif // CHROME_BROWSER_SYNC_ENGINE_PROCESS_COMMIT_RESPONSE_COMMAND_H_ 100 #endif // CHROME_BROWSER_SYNC_ENGINE_PROCESS_COMMIT_RESPONSE_COMMAND_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698