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

Unified Diff: sync/syncable/parent_child_index.h

Issue 1008993004: Sync: Handle empty (implicit) ParentId in GetPredecessorId and GetSuccessorId (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added extra unit test. Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sync/syncable/directory_unittest.cc ('k') | sync/syncable/parent_child_index.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sync/syncable/parent_child_index.h
diff --git a/sync/syncable/parent_child_index.h b/sync/syncable/parent_child_index.h
index 5b51597e2247436ca426cd2bbb4175d9d812d1ec..84c0771403e566642e6065962f463bb0d9cde16a 100644
--- a/sync/syncable/parent_child_index.h
+++ b/sync/syncable/parent_child_index.h
@@ -49,7 +49,14 @@ class SYNC_EXPORT_PRIVATE ParentChildIndex {
// Returns all children of the entry with the given Id. Returns NULL if the
// node has no children or the Id does not identify a valid directory node.
- const OrderedChildSet* GetChildren(const Id& id);
+ const OrderedChildSet* GetChildren(const Id& id) const;
+
+ // Returns all children of the entry. Returns NULL if the node has no
+ // children.
+ const OrderedChildSet* GetChildren(EntryKernel* e) const;
+
+ // Returns all siblings of the entry.
+ const OrderedChildSet* GetSiblings(EntryKernel* e) const;
private:
friend class ParentChildIndexTest;
« no previous file with comments | « sync/syncable/directory_unittest.cc ('k') | sync/syncable/parent_child_index.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698