OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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 #include "sync/syncable/directory.h" | 5 #include "sync/syncable/directory.h" |
6 | 6 |
7 #include "base/debug/trace_event.h" | 7 #include "base/debug/trace_event.h" |
8 #include "base/perftimer.h" | 8 #include "base/perftimer.h" |
9 #include "base/stl_util.h" | 9 #include "base/stl_util.h" |
10 #include "base/string_number_conversions.h" | 10 #include "base/string_number_conversions.h" |
11 #include "sync/internal_api/public/base/node_ordinal.h" | 11 #include "sync/internal_api/public/base/node_ordinal.h" |
12 #include "sync/internal_api/public/util/unrecoverable_error_handler.h" | 12 #include "sync/internal_api/public/util/unrecoverable_error_handler.h" |
13 #include "sync/syncable/base_transaction.h" | |
14 #include "sync/syncable/entry.h" | 13 #include "sync/syncable/entry.h" |
15 #include "sync/syncable/entry_kernel.h" | 14 #include "sync/syncable/entry_kernel.h" |
16 #include "sync/syncable/in_memory_directory_backing_store.h" | 15 #include "sync/syncable/in_memory_directory_backing_store.h" |
17 #include "sync/syncable/on_disk_directory_backing_store.h" | 16 #include "sync/syncable/on_disk_directory_backing_store.h" |
18 #include "sync/syncable/read_transaction.h" | |
19 #include "sync/syncable/scoped_index_updater.h" | 17 #include "sync/syncable/scoped_index_updater.h" |
20 #include "sync/syncable/syncable-inl.h" | 18 #include "sync/syncable/syncable-inl.h" |
| 19 #include "sync/syncable/syncable_base_transaction.h" |
21 #include "sync/syncable/syncable_changes_version.h" | 20 #include "sync/syncable/syncable_changes_version.h" |
| 21 #include "sync/syncable/syncable_read_transaction.h" |
22 #include "sync/syncable/syncable_util.h" | 22 #include "sync/syncable/syncable_util.h" |
23 #include "sync/syncable/write_transaction.h" | 23 #include "sync/syncable/syncable_write_transaction.h" |
24 | 24 |
25 using std::string; | 25 using std::string; |
26 | 26 |
27 namespace syncer { | 27 namespace syncer { |
28 namespace syncable { | 28 namespace syncable { |
29 | 29 |
30 namespace { | 30 namespace { |
31 // Helper function to add an item to the index, if it ought to be added. | 31 // Helper function to add an item to the index, if it ought to be added. |
32 template<typename Indexer> | 32 template<typename Indexer> |
33 void InitializeIndexEntry(EntryKernel* entry, | 33 void InitializeIndexEntry(EntryKernel* entry, |
(...skipping 1231 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1265 // There were no children in the linked list. | 1265 // There were no children in the linked list. |
1266 return NULL; | 1266 return NULL; |
1267 } | 1267 } |
1268 | 1268 |
1269 ScopedKernelLock::ScopedKernelLock(const Directory* dir) | 1269 ScopedKernelLock::ScopedKernelLock(const Directory* dir) |
1270 : scoped_lock_(dir->kernel_->mutex), dir_(const_cast<Directory*>(dir)) { | 1270 : scoped_lock_(dir->kernel_->mutex), dir_(const_cast<Directory*>(dir)) { |
1271 } | 1271 } |
1272 | 1272 |
1273 } // namespace syncable | 1273 } // namespace syncable |
1274 } // namespace syncer | 1274 } // namespace syncer |
OLD | NEW |