Composes Dialogue accounts with StatePatch or Action participants. 更多...
#include <DialoguePayment.h>
Public 成员函数 | |
| DialoguePaymentAdapter (DialogueAccountBindings bindings={}) | |
| Construct an adapter with borrowed account bindings. | |
| void | setBindings (DialogueAccountBindings bindings) |
| Replace borrowed account bindings; no balance is copied. | |
| const DialogueAccountBindings & | bindings () const noexcept |
| Return the current borrowed bindings for diagnostics. | |
| eve::Result< eve::transaction::TransactionReceipt > | execute (std::string transactionId, const PaymentSpec &payment, std::span< eve::transaction::ITransactionParticipant * > effects) const |
| Execute a payment and zero or more staged domain effects atomically. | |
| eve::Result< eve::transaction::TransactionReceipt > | executeStateMutation (std::string transactionId, const PaymentSpec &payment, eve::IStateMutation &provider, std::span< const eve::StateMutation > mutations) const |
| Execute a payment together with one StatePatch-compatible mutation set. | |
详细描述
Composes Dialogue accounts with StatePatch or Action participants.
This adapter owns only copied payment configuration and temporary reservation participants. It owns no account balance, world state, action execution, callback, or provider. Participants are prepared in account order and effects are committed after account debits; if an effect fails, already committed debits are compensated. The call is synchronous and non-reentrant on the owner thread.
在文件 DialoguePayment.h 第 130 行定义.
构造及析构函数说明
◆ DialoguePaymentAdapter()
|
explicit |
Construct an adapter with borrowed account bindings.
在文件 DialoguePayment.cpp 第 159 行定义.
成员函数说明
◆ bindings()
|
inlinenoexcept |
Return the current borrowed bindings for diagnostics.
在文件 DialoguePayment.h 第 138 行定义.
被这些函数引用 setBindings().
◆ execute()
| eve::Result< eve::transaction::TransactionReceipt > eve::dialogue::DialoguePaymentAdapter::execute | ( | std::string | transactionId, |
| const PaymentSpec & | payment, | ||
| std::span< eve::transaction::ITransactionParticipant * > | effects | ||
| ) | const |
Execute a payment and zero or more staged domain effects atomically.
- 参数
-
transactionId Non-empty transaction correlation identity. payment Validated money/reputation specification. effects Borrowed transaction participants; they must be unique and any non-compensatable StatePatch participant must be last.
- 返回
- A committed transaction receipt or structured diagnostics.
在文件 DialoguePayment.cpp 第 163 行定义.
引用了 account, eve::Conflict, cost, effect, eve::Diagnostic::error(), eve::transaction::Coordinator::execute(), eve::Result< T >::failure(), index , 以及 eve::InvalidArgument.
被这些函数引用 executeStateMutation().
◆ executeStateMutation()
| eve::Result< eve::transaction::TransactionReceipt > eve::dialogue::DialoguePaymentAdapter::executeStateMutation | ( | std::string | transactionId, |
| const PaymentSpec & | payment, | ||
| eve::IStateMutation & | provider, | ||
| std::span< const eve::StateMutation > | mutations | ||
| ) | const |
Execute a payment together with one StatePatch-compatible mutation set.
- 参数
-
transactionId Non-empty transaction correlation identity. payment Validated money/reputation specification. provider Borrowed all-or-nothing provider, such as StatePatch. mutations Mutation values copied before transaction preparation.
- 返回
- A committed receipt; failure leaves account and provider unchanged.
在文件 DialoguePayment.cpp 第 208 行定义.
◆ setBindings()
| void eve::dialogue::DialoguePaymentAdapter::setBindings | ( | DialogueAccountBindings | bindings | ) |
Replace borrowed account bindings; no balance is copied.
在文件 DialoguePayment.cpp 第 161 行定义.
引用了 bindings().
被这些函数引用 eve::dialogue::DialogueFlow::configureIntegration().
该类的文档由以下文件生成:
- src/modules/dialogue/DialoguePayment.h
- src/modules/dialogue/DialoguePayment.cpp