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

Side by Side Diff: chrome/browser/sync/internal_api/read_transaction.h

Issue 8470005: Add OVERRIDE to chrome/browser/sync/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: includes Created 9 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) 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_INTERNAL_API_READ_TRANSACTION_H_ 5 #ifndef CHROME_BROWSER_SYNC_INTERNAL_API_READ_TRANSACTION_H_
6 #define CHROME_BROWSER_SYNC_INTERNAL_API_READ_TRANSACTION_H_ 6 #define CHROME_BROWSER_SYNC_INTERNAL_API_READ_TRANSACTION_H_
7 7
8 #include "base/compiler_specific.h"
8 #include "chrome/browser/sync/internal_api/base_transaction.h" 9 #include "chrome/browser/sync/internal_api/base_transaction.h"
9 10
10 namespace tracked_objects { 11 namespace tracked_objects {
11 class Location; 12 class Location;
12 } // namespace tracked_objects 13 } // namespace tracked_objects
13 14
14 namespace sync_api { 15 namespace sync_api {
15 16
16 struct UserShare; 17 struct UserShare;
17 18
18 // Sync API's ReadTransaction is a read-only BaseTransaction. It wraps 19 // Sync API's ReadTransaction is a read-only BaseTransaction. It wraps
19 // a syncable::ReadTransaction. 20 // a syncable::ReadTransaction.
20 class ReadTransaction : public BaseTransaction { 21 class ReadTransaction : public BaseTransaction {
21 public: 22 public:
22 // Start a new read-only transaction on the specified repository. 23 // Start a new read-only transaction on the specified repository.
23 ReadTransaction(const tracked_objects::Location& from_here, 24 ReadTransaction(const tracked_objects::Location& from_here,
24 UserShare* share); 25 UserShare* share);
25 26
26 // Resume the middle of a transaction. Will not close transaction. 27 // Resume the middle of a transaction. Will not close transaction.
27 ReadTransaction(UserShare* share, syncable::BaseTransaction* trans); 28 ReadTransaction(UserShare* share, syncable::BaseTransaction* trans);
28 29
29 virtual ~ReadTransaction(); 30 virtual ~ReadTransaction();
30 31
31 // BaseTransaction override. 32 // BaseTransaction override.
32 virtual syncable::BaseTransaction* GetWrappedTrans() const; 33 virtual syncable::BaseTransaction* GetWrappedTrans() const OVERRIDE;
33 private: 34 private:
34 void* operator new(size_t size); // Transaction is meant for stack use only. 35 void* operator new(size_t size); // Transaction is meant for stack use only.
35 36
36 // The underlying syncable object which this class wraps. 37 // The underlying syncable object which this class wraps.
37 syncable::BaseTransaction* transaction_; 38 syncable::BaseTransaction* transaction_;
38 bool close_transaction_; 39 bool close_transaction_;
39 40
40 DISALLOW_COPY_AND_ASSIGN(ReadTransaction); 41 DISALLOW_COPY_AND_ASSIGN(ReadTransaction);
41 }; 42 };
42 43
43 } // namespace sync_api 44 } // namespace sync_api
44 45
45 #endif // CHROME_BROWSER_SYNC_INTERNAL_API_READ_TRANSACTION_H_ 46 #endif // CHROME_BROWSER_SYNC_INTERNAL_API_READ_TRANSACTION_H_
OLDNEW
« no previous file with comments | « chrome/browser/sync/internal_api/read_node.h ('k') | chrome/browser/sync/internal_api/syncapi_server_connection_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698