|
36 | 36 | namespace proton { |
37 | 37 |
|
38 | 38 | class transaction_handler; |
39 | | -// class transaction_impl; |
40 | | - |
41 | | -// TODO: This should not be accessible to users. |
42 | | -// class transaction_impl { |
43 | | -// public: |
44 | | -// proton::sender txn_ctrl; |
45 | | -// proton::transaction_handler *handler = nullptr; |
46 | | -// proton::binary id; |
47 | | -// proton::tracker _declare; |
48 | | -// proton::tracker _discharge; |
49 | | -// bool failed = false; |
50 | | -// std::vector<proton::tracker> pending; |
51 | | - |
52 | | -// void commit(); |
53 | | -// void abort(); |
54 | | -// void declare(); |
55 | | -// proton::tracker send(proton::sender s, proton::message msg); |
56 | | - |
57 | | -// void discharge(bool failed); |
58 | | -// void release_pending(); |
59 | | -// void accept(delivery &d); |
60 | | -// void update(tracker &d, uint64_t state); |
61 | | -// void set_id(binary _id); |
62 | | - |
63 | | -// proton::tracker send_ctrl(proton::symbol descriptor, proton::value _value); |
64 | | -// void handle_outcome(proton::tracker t); |
65 | | -// transaction_impl(proton::sender &_txn_ctrl, |
66 | | -// proton::transaction_handler &_handler, |
67 | | -// bool _settle_before_discharge); |
68 | | - |
69 | | -// // delete copy and assignment operator to ensure no copy of this object is |
70 | | -// // every made transaction_impl(const transaction_impl&) = delete; |
71 | | -// // transaction_impl& operator=(const transaction_impl&) = delete; |
72 | | -// }; |
73 | | - |
74 | | -// class |
75 | | -// PN_CPP_CLASS_EXTERN transaction { |
76 | | -// private: |
77 | | -// // PN_CPP_EXTERN transaction(proton::sender& _txn_ctrl, |
78 | | -// // proton::transaction_handler& _handler, bool _settle_before_discharge); |
79 | | - |
80 | | -// static transaction mk_transaction_impl(sender &s, transaction_handler &h, |
81 | | -// bool f); |
82 | | -// PN_CPP_EXTERN transaction(transaction_impl *impl); |
83 | | -// transaction_impl *_impl; |
84 | | - |
85 | | -// public: |
86 | | -// // TODO: |
87 | | -// // PN_CPP_EXTERN transaction(transaction &o); |
88 | | -// PN_CPP_EXTERN transaction(); |
89 | | -// PN_CPP_EXTERN ~transaction(); |
90 | | -// PN_CPP_EXTERN bool is_empty(); |
91 | | -// PN_CPP_EXTERN void commit(); |
92 | | -// PN_CPP_EXTERN void abort(); |
93 | | -// PN_CPP_EXTERN void declare(); |
94 | | -// PN_CPP_EXTERN void handle_outcome(proton::tracker); |
95 | | -// PN_CPP_EXTERN proton::tracker send(proton::sender s, proton::message msg); |
96 | | -// PN_CPP_EXTERN void accept(delivery &t); |
97 | | -// PN_CPP_EXTERN proton::connection connection() const; |
98 | | - |
99 | | -// friend class transaction_impl; |
100 | | -// friend class session; |
101 | | -// }; |
102 | 39 |
|
103 | 40 | class |
104 | 41 | PN_CPP_CLASS_EXTERN transaction_handler { |
|
0 commit comments