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

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

Issue 7633077: Refactor syncapi.h (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: This patch has compiled from a clean build Created 9 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 // Defines ChangeReorderBuffer, which can be used to sort a list of item 5 // Defines ChangeReorderBuffer, which can be used to sort a list of item
6 // actions to achieve the ordering constraint required by the SyncObserver 6 // actions to achieve the ordering constraint required by the SyncObserver
7 // interface of the SyncAPI. 7 // interface of the SyncAPI.
8 8
9 #ifndef CHROME_BROWSER_SYNC_ENGINE_CHANGE_REORDER_BUFFER_H_ 9 #ifndef CHROME_BROWSER_SYNC_ENGINE_CHANGE_REORDER_BUFFER_H_
10 #define CHROME_BROWSER_SYNC_ENGINE_CHANGE_REORDER_BUFFER_H_ 10 #define CHROME_BROWSER_SYNC_ENGINE_CHANGE_REORDER_BUFFER_H_
11 #pragma once 11 #pragma once
12 12
13 #include <map> 13 #include <map>
14 #include <vector> 14 #include <vector>
15 15
16 #include "base/memory/linked_ptr.h" 16 #include "base/memory/linked_ptr.h"
17 #include "chrome/browser/sync/engine/syncapi.h" 17 #include "chrome/browser/sync/internal_api/base_transaction.h"
18 #include "chrome/browser/sync/internal_api/sync_manager.h"
18 #include "chrome/browser/sync/protocol/sync.pb.h" 19 #include "chrome/browser/sync/protocol/sync.pb.h"
19 20
20 namespace sync_api { 21 namespace sync_api {
21 22
22 // ChangeReorderBuffer is a utility type which accepts an unordered set 23 // ChangeReorderBuffer is a utility type which accepts an unordered set
23 // of changes (via its Push methods), and yields a vector of ChangeRecords 24 // of changes (via its Push methods), and yields a vector of ChangeRecords
24 // (via the GetAllChangesInTreeOrder method) that are in the order that 25 // (via the GetAllChangesInTreeOrder method) that are in the order that
25 // the SyncObserver expects them to be. A buffer is initially empty. 26 // the SyncObserver expects them to be. A buffer is initially empty.
26 // 27 //
27 // The ordering produced by ChangeReorderBuffer is as follows: 28 // The ordering produced by ChangeReorderBuffer is as follows:
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 114
114 // Stores type-specific extra data per-ID. 115 // Stores type-specific extra data per-ID.
115 ExtraDataMap extra_data_; 116 ExtraDataMap extra_data_;
116 117
117 DISALLOW_COPY_AND_ASSIGN(ChangeReorderBuffer); 118 DISALLOW_COPY_AND_ASSIGN(ChangeReorderBuffer);
118 }; 119 };
119 120
120 } // namespace sync_api 121 } // namespace sync_api
121 122
122 #endif // CHROME_BROWSER_SYNC_ENGINE_CHANGE_REORDER_BUFFER_H_ 123 #endif // CHROME_BROWSER_SYNC_ENGINE_CHANGE_REORDER_BUFFER_H_
OLDNEW
« no previous file with comments | « chrome/browser/sync/engine/all_status.h ('k') | chrome/browser/sync/engine/change_reorder_buffer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698