| Apache Ignite C++

transactions.h
Go to the documentation of this file.
1 /*
2 * Licensed to the Apache Software Foundation (ASF) under one or more
3 * contributor license agreements. See the NOTICE file distributed with
4 * this work for additional information regarding copyright ownership.
5 * The ASF licenses this file to You under the Apache License, Version 2.0
6 * (the "License"); you may not use this file except in compliance with
7 * the License. You may obtain a copy of the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 */
17
23 #ifndef _IGNITE_TRANSACTIONS_TRANSACTIONS
24 #define _IGNITE_TRANSACTIONS_TRANSACTIONS
25
26 #include <ignite/common/concurrent.h>
27 #include <ignite/jni/java.h>
28
29 #include "ignite/transactions/transaction.h"
30 #include "ignite/transactions/transaction_metrics.h"
31 #include "ignite/impl/transactions/transactions_impl.h"
32
33 namespace ignite
34 {
35 namespace transactions
36 {
45 class IGNITE_FRIEND_EXPORT Transactions
46 {
47 public:
55 Transactions(ignite::common::concurrent::SharedPointer<impl::transactions::TransactionsImpl> impl);
56
62 Transactions(const Transactions& other);
63
70 Transactions& operator=(const Transactions& other);
71
75 ~Transactions();
76
84 Transaction GetTx();
85
92 Transaction TxStart();
93
101 Transaction TxStart(IgniteError& err);
102
111 Transaction TxStart(TransactionConcurrency::Type concurrency,
112 TransactionIsolation::Type isolation);
113
123 Transaction TxStart(TransactionConcurrency::Type concurrency,
124 TransactionIsolation::Type isolation, IgniteError& err);
125
137 Transaction TxStart(TransactionConcurrency::Type concurrency,
138 TransactionIsolation::Type isolation, int64_t timeout,
139 int32_t txSize);
140
152 Transaction TxStart(TransactionConcurrency::Type concurrency,
153 TransactionIsolation::Type isolation, int64_t timeout,
154 int32_t txSize, IgniteError& err);
155
161 TransactionMetrics GetMetrics();
162
171 TransactionMetrics GetMetrics(IgniteError& err);
172
173 private:
175 ignite::common::concurrent::SharedPointer<impl::transactions::TransactionsImpl> impl;
176 };
177 }
178 }
179
180 #endif //_IGNITE_TRANSACTIONS_TRANSACTIONS
transaction_metrics.h
Declares ignite::transactions::TransactionMetrics class.
ignite::transactions::Transaction
Ignite cache transaction.
Definition: transaction.h:47
ignite::transactions::Transactions
Transactions facade.
Definition: transactions.h:45
ignite::transactions::TransactionMetrics
Transaction metrics, shared across all caches.
Definition: transaction_metrics.h:37
ignite::IgniteError
Ignite error information.
Definition: ignite_error.h:94
ignite::transactions::TransactionIsolation::Type
Type
Definition: transaction_consts.h:73
ignite
Apache Ignite API.
Definition: cache.h:48
transaction.h
Declares ignite::transactions::Transaction class.
ignite::transactions::TransactionConcurrency::Type
Type
Definition: transaction_consts.h:35