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

Side by Side Diff: sync/engine/syncer_util.h

Issue 1545553003: Switch to standard integer types in sync/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 12 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 unified diff | Download patch
« no previous file with comments | « sync/engine/syncer_unittest.cc ('k') | sync/engine/syncer_util.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 10
11 #include <stdint.h>
12
11 #include <set> 13 #include <set>
12 #include <string> 14 #include <string>
13 #include <vector> 15 #include <vector>
14 16
15 #include "sync/base/sync_export.h" 17 #include "sync/base/sync_export.h"
16 #include "sync/engine/syncer.h" 18 #include "sync/engine/syncer.h"
17 #include "sync/engine/syncer_types.h" 19 #include "sync/engine/syncer_types.h"
18 #include "sync/syncable/entry_kernel.h" 20 #include "sync/syncable/entry_kernel.h"
19 #include "sync/syncable/metahandle_set.h" 21 #include "sync/syncable/metahandle_set.h"
20 #include "sync/syncable/mutable_entry.h" 22 #include "sync/syncable/mutable_entry.h"
(...skipping 25 matching lines...) Expand all
46 syncable::BaseTransaction* trans, 48 syncable::BaseTransaction* trans,
47 const sync_pb::SyncEntity& server_entry); 49 const sync_pb::SyncEntity& server_entry);
48 50
49 UpdateAttemptResponse AttemptToUpdateEntry( 51 UpdateAttemptResponse AttemptToUpdateEntry(
50 syncable::WriteTransaction* const trans, 52 syncable::WriteTransaction* const trans,
51 syncable::MutableEntry* const entry, 53 syncable::MutableEntry* const entry,
52 Cryptographer* cryptographer); 54 Cryptographer* cryptographer);
53 55
54 // Returns the most accurate position information available in this update. It 56 // Returns the most accurate position information available in this update. It
55 // prefers to use the unique_position() field, but will fall back to using the 57 // prefers to use the unique_position() field, but will fall back to using the
56 // int64-based position_in_parent if necessary. 58 // int64_t-based position_in_parent if necessary.
57 // 59 //
58 // The suffix parameter is the unique bookmark tag for the item being updated. 60 // The suffix parameter is the unique bookmark tag for the item being updated.
59 // 61 //
60 // Will return an invalid position if no valid position can be constructed, or 62 // Will return an invalid position if no valid position can be constructed, or
61 // if this type does not support positioning. 63 // if this type does not support positioning.
62 SYNC_EXPORT UniquePosition GetUpdatePosition(const sync_pb::SyncEntity& update, 64 SYNC_EXPORT UniquePosition GetUpdatePosition(const sync_pb::SyncEntity& update,
63 const std::string& suffix); 65 const std::string& suffix);
64 66
65 // Fetch the cache_guid and item_id-based unique bookmark tag from an update. 67 // Fetch the cache_guid and item_id-based unique bookmark tag from an update.
66 // Will return an empty string if someting unexpected happens. 68 // Will return an empty string if someting unexpected happens.
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 syncable::ModelNeutralMutableEntry* target); 107 syncable::ModelNeutralMutableEntry* target);
106 108
107 void MarkDeletedChildrenSynced( 109 void MarkDeletedChildrenSynced(
108 syncable::Directory* dir, 110 syncable::Directory* dir,
109 syncable::BaseWriteTransaction* trans, 111 syncable::BaseWriteTransaction* trans,
110 std::set<syncable::Id>* deleted_folders); 112 std::set<syncable::Id>* deleted_folders);
111 113
112 } // namespace syncer 114 } // namespace syncer
113 115
114 #endif // SYNC_ENGINE_SYNCER_UTIL_H_ 116 #endif // SYNC_ENGINE_SYNCER_UTIL_H_
OLDNEW
« no previous file with comments | « sync/engine/syncer_unittest.cc ('k') | sync/engine/syncer_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698