| OLD | NEW |
| 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 #ifndef CHROME_BROWSER_SYNC_SYNCABLE_SYNCABLE_H_ | 5 #ifndef CHROME_BROWSER_SYNC_SYNCABLE_SYNCABLE_H_ |
| 6 #define CHROME_BROWSER_SYNC_SYNCABLE_SYNCABLE_H_ | 6 #define CHROME_BROWSER_SYNC_SYNCABLE_SYNCABLE_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <bitset> | 10 #include <bitset> |
| (...skipping 953 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 964 // Get GetUnsyncedMetaHandles should only be called after SaveChanges and | 964 // Get GetUnsyncedMetaHandles should only be called after SaveChanges and |
| 965 // before any new entries have been created. The intention is that the | 965 // before any new entries have been created. The intention is that the |
| 966 // syncer should call it from its PerformSyncQueries member. | 966 // syncer should call it from its PerformSyncQueries member. |
| 967 typedef std::vector<int64> UnsyncedMetaHandles; | 967 typedef std::vector<int64> UnsyncedMetaHandles; |
| 968 void GetUnsyncedMetaHandles(BaseTransaction* trans, | 968 void GetUnsyncedMetaHandles(BaseTransaction* trans, |
| 969 UnsyncedMetaHandles* result); | 969 UnsyncedMetaHandles* result); |
| 970 | 970 |
| 971 // Returns all server types with unapplied updates. A subset of | 971 // Returns all server types with unapplied updates. A subset of |
| 972 // those types can then be passed into | 972 // those types can then be passed into |
| 973 // GetUnappliedUpdateMetaHandles() below. | 973 // GetUnappliedUpdateMetaHandles() below. |
| 974 syncable::ModelTypeBitSet GetServerTypesWithUnappliedUpdates( | 974 FullModelEnumSet GetServerTypesWithUnappliedUpdates( |
| 975 BaseTransaction* trans) const; | 975 BaseTransaction* trans) const; |
| 976 | 976 |
| 977 // Get all the metahandles for unapplied updates for a given set of | 977 // Get all the metahandles for unapplied updates for a given set of |
| 978 // server types. | 978 // server types. |
| 979 typedef std::vector<int64> UnappliedUpdateMetaHandles; | 979 typedef std::vector<int64> UnappliedUpdateMetaHandles; |
| 980 void GetUnappliedUpdateMetaHandles(BaseTransaction* trans, | 980 void GetUnappliedUpdateMetaHandles(BaseTransaction* trans, |
| 981 syncable::ModelTypeBitSet server_types, | 981 FullModelEnumSet server_types, |
| 982 UnappliedUpdateMetaHandles* result); | 982 UnappliedUpdateMetaHandles* result); |
| 983 | 983 |
| 984 // Checks tree metadata consistency. | 984 // Checks tree metadata consistency. |
| 985 // If full_scan is false, the function will avoid pulling any entries from the | 985 // If full_scan is false, the function will avoid pulling any entries from the |
| 986 // db and scan entries currently in ram. | 986 // db and scan entries currently in ram. |
| 987 // If full_scan is true, all entries will be pulled from the database. | 987 // If full_scan is true, all entries will be pulled from the database. |
| 988 // No return value, CHECKs will be triggered if we're given bad | 988 // No return value, CHECKs will be triggered if we're given bad |
| 989 // information. | 989 // information. |
| 990 void CheckTreeInvariants(syncable::BaseTransaction* trans, | 990 void CheckTreeInvariants(syncable::BaseTransaction* trans, |
| 991 bool full_scan); | 991 bool full_scan); |
| (...skipping 288 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1280 bool IsLegalNewParent(BaseTransaction* trans, const Id& id, const Id& parentid); | 1280 bool IsLegalNewParent(BaseTransaction* trans, const Id& id, const Id& parentid); |
| 1281 | 1281 |
| 1282 // This function sets only the flags needed to get this entry to sync. | 1282 // This function sets only the flags needed to get this entry to sync. |
| 1283 void MarkForSyncing(syncable::MutableEntry* e); | 1283 void MarkForSyncing(syncable::MutableEntry* e); |
| 1284 | 1284 |
| 1285 } // namespace syncable | 1285 } // namespace syncable |
| 1286 | 1286 |
| 1287 std::ostream& operator <<(std::ostream&, const syncable::Blob&); | 1287 std::ostream& operator <<(std::ostream&, const syncable::Blob&); |
| 1288 | 1288 |
| 1289 #endif // CHROME_BROWSER_SYNC_SYNCABLE_SYNCABLE_H_ | 1289 #endif // CHROME_BROWSER_SYNC_SYNCABLE_SYNCABLE_H_ |
| OLD | NEW |