| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 // Utility functions manipulating syncable::Entries, intended for use by the | 5 // Utility functions manipulating syncable::Entries, intended for use by the |
| 6 // syncer. | 6 // syncer. |
| 7 | 7 |
| 8 #ifndef SYNC_ENGINE_SYNCER_UTIL_H_ | 8 #ifndef SYNC_ENGINE_SYNCER_UTIL_H_ |
| 9 #define SYNC_ENGINE_SYNCER_UTIL_H_ | 9 #define SYNC_ENGINE_SYNCER_UTIL_H_ |
| 10 #pragma once | 10 #pragma once |
| 11 | 11 |
| 12 #include <set> | 12 #include <set> |
| 13 #include <string> | 13 #include <string> |
| 14 #include <vector> | 14 #include <vector> |
| 15 | 15 |
| 16 #include "sync/engine/syncer.h" | 16 #include "sync/engine/syncer.h" |
| 17 #include "sync/engine/syncer_types.h" | 17 #include "sync/engine/syncer_types.h" |
| 18 #include "sync/syncable/entry_kernel.h" | 18 #include "sync/syncable/entry_kernel.h" |
| 19 #include "sync/syncable/metahandle_set.h" | 19 #include "sync/syncable/metahandle_set.h" |
| 20 #include "sync/syncable/syncable_id.h" | 20 #include "sync/syncable/syncable_id.h" |
| 21 | 21 |
| 22 namespace csync { | 22 namespace syncer { |
| 23 | 23 |
| 24 class Cryptographer; | 24 class Cryptographer; |
| 25 class SyncEntity; | 25 class SyncEntity; |
| 26 | 26 |
| 27 class SyncerUtil { | 27 class SyncerUtil { |
| 28 public: | 28 public: |
| 29 // Returns the number of unsynced entries. | 29 // Returns the number of unsynced entries. |
| 30 static int GetUnsyncedEntries(syncable::BaseTransaction* trans, | 30 static int GetUnsyncedEntries(syncable::BaseTransaction* trans, |
| 31 std::vector<int64> *handles); | 31 std::vector<int64> *handles); |
| 32 | 32 |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 116 std::vector<syncable::Id>* commit_ids); | 116 std::vector<syncable::Id>* commit_ids); |
| 117 | 117 |
| 118 static void MarkDeletedChildrenSynced( | 118 static void MarkDeletedChildrenSynced( |
| 119 syncable::Directory* dir, | 119 syncable::Directory* dir, |
| 120 std::set<syncable::Id>* deleted_folders); | 120 std::set<syncable::Id>* deleted_folders); |
| 121 | 121 |
| 122 private: | 122 private: |
| 123 DISALLOW_IMPLICIT_CONSTRUCTORS(SyncerUtil); | 123 DISALLOW_IMPLICIT_CONSTRUCTORS(SyncerUtil); |
| 124 }; | 124 }; |
| 125 | 125 |
| 126 } // namespace csync | 126 } // namespace syncer |
| 127 | 127 |
| 128 #endif // SYNC_ENGINE_SYNCER_UTIL_H_ | 128 #endif // SYNC_ENGINE_SYNCER_UTIL_H_ |
| OLD | NEW |