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

Side by Side Diff: sync/internal_api/public/read_transaction.h

Issue 11341048: Populate versions on individual nodes in sync model and native bookmark model. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Restore heap unallocatability of write transaction Created 8 years, 1 month 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 | Annotate | Revision Log
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 #ifndef SYNC_INTERNAL_API_PUBLIC_READ_TRANSACTION_H_ 5 #ifndef SYNC_INTERNAL_API_PUBLIC_READ_TRANSACTION_H_
6 #define SYNC_INTERNAL_API_PUBLIC_READ_TRANSACTION_H_ 6 #define SYNC_INTERNAL_API_PUBLIC_READ_TRANSACTION_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "sync/internal_api/public/base_transaction.h" 9 #include "sync/internal_api/public/base_transaction.h"
10 10
(...skipping 14 matching lines...) Expand all
25 UserShare* share); 25 UserShare* share);
26 26
27 // Resume the middle of a transaction. Will not close transaction. 27 // Resume the middle of a transaction. Will not close transaction.
28 ReadTransaction(UserShare* share, syncable::BaseTransaction* trans); 28 ReadTransaction(UserShare* share, syncable::BaseTransaction* trans);
29 29
30 virtual ~ReadTransaction(); 30 virtual ~ReadTransaction();
31 31
32 // BaseTransaction override. 32 // BaseTransaction override.
33 virtual syncable::BaseTransaction* GetWrappedTrans() const OVERRIDE; 33 virtual syncable::BaseTransaction* GetWrappedTrans() const OVERRIDE;
34 34
35 // Return |transaction_version| of |type| stored in sync directory's
36 // persisted info.
37 int64 GetModelVersion(ModelType type);
38
39 private: 35 private:
40 void* operator new(size_t size); // Transaction is meant for stack use only. 36 void* operator new(size_t size); // Transaction is meant for stack use only.
41 37
42 // The underlying syncable object which this class wraps. 38 // The underlying syncable object which this class wraps.
43 syncable::BaseTransaction* transaction_; 39 syncable::BaseTransaction* transaction_;
44 bool close_transaction_; 40 bool close_transaction_;
45 41
46 DISALLOW_COPY_AND_ASSIGN(ReadTransaction); 42 DISALLOW_COPY_AND_ASSIGN(ReadTransaction);
47 }; 43 };
48 44
49 } // namespace syncer 45 } // namespace syncer
50 46
51 #endif // SYNC_INTERNAL_API_PUBLIC_READ_TRANSACTION_H_ 47 #endif // SYNC_INTERNAL_API_PUBLIC_READ_TRANSACTION_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698