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

Unified Diff: sync/syncable/scoped_parent_child_index_updater.h

Issue 11636006: WIP: The Bookmark Position Megapatch (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Various updates, including switch suffix to unique_client_tag style Created 8 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sync/syncable/parent_child_index.cc ('k') | sync/syncable/scoped_parent_child_index_updater.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sync/syncable/scoped_parent_child_index_updater.h
diff --git a/sync/syncable/scoped_parent_child_index_updater.h b/sync/syncable/scoped_parent_child_index_updater.h
new file mode 100644
index 0000000000000000000000000000000000000000..f9e99d969d7781a3588dab34e453a8a1272cee17
--- /dev/null
+++ b/sync/syncable/scoped_parent_child_index_updater.h
@@ -0,0 +1,32 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef SYNC_SYNCABLE_PARENT_CHILD_INDEX_UPDATER_H_
+#define SYNC_SYNCABLE_PARENT_CHILD_INDEX_UPDATER_H_
+
+namespace syncer {
+namespace syncable {
+
+class ParentChildIndex;
+class ScopedKernelLock;
+struct EntryKernel;
+
+// Temporarily removes an item from the ParentChildIndex and re-adds it this
+// object goes out of scope.
+class ScopedParentChildIndexUpdater {
+ public:
+ ScopedParentChildIndexUpdater(ScopedKernelLock& proof_of_lock,
+ EntryKernel* entry,
+ ParentChildIndex* index);
+ ~ScopedParentChildIndexUpdater();
+
+ private:
+ EntryKernel* entry_;
+ ParentChildIndex* index_;
+};
+
+} // namespace syncer
+} // namespace syncable
+
+#endif // SYNC_SYNCABLE_PARENT_CHILD_INDEX_UPDATER_H_
« no previous file with comments | « sync/syncable/parent_child_index.cc ('k') | sync/syncable/scoped_parent_child_index_updater.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698