OLD | NEW |
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 SQL_TRANSACTION_H_ | 5 #ifndef SQL_TRANSACTION_H_ |
6 #define SQL_TRANSACTION_H_ | 6 #define SQL_TRANSACTION_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/macros.h" |
9 #include "sql/sql_export.h" | 9 #include "sql/sql_export.h" |
10 | 10 |
11 namespace sql { | 11 namespace sql { |
12 | 12 |
13 class Connection; | 13 class Connection; |
14 | 14 |
15 class SQL_EXPORT Transaction { | 15 class SQL_EXPORT Transaction { |
16 public: | 16 public: |
17 // Creates the scoped transaction object. You MUST call Begin() to begin the | 17 // Creates the scoped transaction object. You MUST call Begin() to begin the |
18 // transaction. If you have begun a transaction and not committed it, the | 18 // transaction. If you have begun a transaction and not committed it, the |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
51 // True when the transaction is open, false when it's already been committed | 51 // True when the transaction is open, false when it's already been committed |
52 // or rolled back. | 52 // or rolled back. |
53 bool is_open_; | 53 bool is_open_; |
54 | 54 |
55 DISALLOW_COPY_AND_ASSIGN(Transaction); | 55 DISALLOW_COPY_AND_ASSIGN(Transaction); |
56 }; | 56 }; |
57 | 57 |
58 } // namespace sql | 58 } // namespace sql |
59 | 59 |
60 #endif // SQL_TRANSACTION_H_ | 60 #endif // SQL_TRANSACTION_H_ |
OLD | NEW |