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

Side by Side Diff: components/sync/syncable/model_neutral_mutable_entry.h

Issue 2240613002: [Sync] Convert sync to a static library. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Try getting rid of sync_core source set. Created 4 years, 4 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 COMPONENTS_SYNC_SYNCABLE_MODEL_NEUTRAL_MUTABLE_ENTRY_H_ 5 #ifndef COMPONENTS_SYNC_SYNCABLE_MODEL_NEUTRAL_MUTABLE_ENTRY_H_
6 #define COMPONENTS_SYNC_SYNCABLE_MODEL_NEUTRAL_MUTABLE_ENTRY_H_ 6 #define COMPONENTS_SYNC_SYNCABLE_MODEL_NEUTRAL_MUTABLE_ENTRY_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
11 #include <string> 11 #include <string>
12 12
13 #include "base/macros.h" 13 #include "base/macros.h"
14 #include "components/sync/base/model_type.h" 14 #include "components/sync/base/model_type.h"
15 #include "components/sync/base/sync_export.h"
16 #include "components/sync/syncable/entry.h" 15 #include "components/sync/syncable/entry.h"
17 16
18 namespace syncer { 17 namespace syncer {
19 class WriteNode; 18 class WriteNode;
20 19
21 namespace syncable { 20 namespace syncable {
22 21
23 class BaseWriteTransaction; 22 class BaseWriteTransaction;
24 23
25 enum CreateNewUpdateItem { CREATE_NEW_UPDATE_ITEM }; 24 enum CreateNewUpdateItem { CREATE_NEW_UPDATE_ITEM };
26 25
27 enum CreateNewTypeRoot { CREATE_NEW_TYPE_ROOT }; 26 enum CreateNewTypeRoot { CREATE_NEW_TYPE_ROOT };
28 27
29 // This Entry includes all the operations one can safely perform on the sync 28 // This Entry includes all the operations one can safely perform on the sync
30 // thread. In particular, it does not expose setters to make changes that need 29 // thread. In particular, it does not expose setters to make changes that need
31 // to be communicated to the model (and the model's thread). It is not possible 30 // to be communicated to the model (and the model's thread). It is not possible
32 // to change an entry's SPECIFICS or UNIQUE_POSITION fields with this kind of 31 // to change an entry's SPECIFICS or UNIQUE_POSITION fields with this kind of
33 // entry. 32 // entry.
34 class SYNC_EXPORT ModelNeutralMutableEntry : public Entry { 33 class ModelNeutralMutableEntry : public Entry {
35 public: 34 public:
36 ModelNeutralMutableEntry(BaseWriteTransaction* trans, 35 ModelNeutralMutableEntry(BaseWriteTransaction* trans,
37 CreateNewUpdateItem, 36 CreateNewUpdateItem,
38 const Id& id); 37 const Id& id);
39 ModelNeutralMutableEntry(BaseWriteTransaction* trans, 38 ModelNeutralMutableEntry(BaseWriteTransaction* trans,
40 CreateNewTypeRoot, 39 CreateNewTypeRoot,
41 ModelType type); 40 ModelType type);
42 ModelNeutralMutableEntry(BaseWriteTransaction* trans, GetByHandle, int64_t); 41 ModelNeutralMutableEntry(BaseWriteTransaction* trans, GetByHandle, int64_t);
43 ModelNeutralMutableEntry(BaseWriteTransaction* trans, GetById, const Id&); 42 ModelNeutralMutableEntry(BaseWriteTransaction* trans, GetById, const Id&);
44 ModelNeutralMutableEntry(BaseWriteTransaction* trans, 43 ModelNeutralMutableEntry(BaseWriteTransaction* trans,
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
116 // Scope: Set on construction, never changed after that. 115 // Scope: Set on construction, never changed after that.
117 BaseWriteTransaction* const base_write_transaction_; 116 BaseWriteTransaction* const base_write_transaction_;
118 117
119 DISALLOW_COPY_AND_ASSIGN(ModelNeutralMutableEntry); 118 DISALLOW_COPY_AND_ASSIGN(ModelNeutralMutableEntry);
120 }; 119 };
121 120
122 } // namespace syncable 121 } // namespace syncable
123 } // namespace syncer 122 } // namespace syncer
124 123
125 #endif // COMPONENTS_SYNC_SYNCABLE_MODEL_NEUTRAL_MUTABLE_ENTRY_H_ 124 #endif // COMPONENTS_SYNC_SYNCABLE_MODEL_NEUTRAL_MUTABLE_ENTRY_H_
OLDNEW
« no previous file with comments | « components/sync/syncable/invalid_directory_backing_store.h ('k') | components/sync/syncable/mutable_entry.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698