4#include <xrpl/protocol/STTx.h>
5#include <xrpl/protocol/STParsedJSON.h>
6#include <xrpl/protocol/jss.h>
7#include <xrpl/protocol_autogen/TransactionBase.h>
8#include <xrpl/protocol_autogen/TransactionBuilderBase.h>
9#include <xrpl/json/json_value.h>
44 throw std::runtime_error(
"Invalid transaction type for ConfidentialMPTClawback");
55 SF_UINT192::type::value_type
58 return this->
tx_->at(sfMPTokenIssuanceID);
66 SF_ACCOUNT::type::value_type
69 return this->
tx_->at(sfHolder);
77 SF_UINT64::type::value_type
80 return this->
tx_->at(sfMPTAmount);
88 SF_VL::type::value_type
91 return this->
tx_->at(sfZKProof);
134 if (tx->getTxnType() != ttCONFIDENTIAL_MPT_CLAWBACK)
136 throw std::runtime_error(
"Invalid transaction type for ConfidentialMPTClawbackBuilder");
150 object_[sfMPTokenIssuanceID] = value;
196 sign(publicKey, secretKey);
Builder for ConfidentialMPTClawback transactions.
ConfidentialMPTClawbackBuilder(std::shared_ptr< STTx const > tx)
Construct a ConfidentialMPTClawbackBuilder from an existing STTx object.
ConfidentialMPTClawbackBuilder & setZKProof(std::decay_t< typename SF_VL::type::value_type > const &value)
Set sfZKProof (SoeRequired).
ConfidentialMPTClawbackBuilder & setHolder(std::decay_t< typename SF_ACCOUNT::type::value_type > const &value)
Set sfHolder (SoeRequired).
ConfidentialMPTClawback build(PublicKey const &publicKey, SecretKey const &secretKey)
Build and return the ConfidentialMPTClawback wrapper.
ConfidentialMPTClawbackBuilder & setMPTokenIssuanceID(std::decay_t< typename SF_UINT192::type::value_type > const &value)
Transaction-specific field setters.
ConfidentialMPTClawbackBuilder & setMPTAmount(std::decay_t< typename SF_UINT64::type::value_type > const &value)
Set sfMPTAmount (SoeRequired).
ConfidentialMPTClawbackBuilder(SF_ACCOUNT::type::value_type account, std::decay_t< typename SF_UINT192::type::value_type > const &mPTokenIssuanceID, std::decay_t< typename SF_ACCOUNT::type::value_type > const &holder, std::decay_t< typename SF_UINT64::type::value_type > const &mPTAmount, std::decay_t< typename SF_VL::type::value_type > const &zKProof, std::optional< SF_UINT32::type::value_type > sequence=std::nullopt, std::optional< SF_AMOUNT::type::value_type > fee=std::nullopt)
Construct a new ConfidentialMPTClawbackBuilder with required fields.
Transaction: ConfidentialMPTClawback.
static constexpr xrpl::TxType txType
SF_UINT192::type::value_type getMPTokenIssuanceID() const
Get sfMPTokenIssuanceID (SoeRequired).
ConfidentialMPTClawback(std::shared_ptr< STTx const > tx)
Construct a ConfidentialMPTClawback transaction wrapper from an existing STTx object.
SF_UINT64::type::value_type getMPTAmount() const
Get sfMPTAmount (SoeRequired).
SF_VL::type::value_type getZKProof() const
Get sfZKProof (SoeRequired).
SF_ACCOUNT::type::value_type getHolder() const
Get sfHolder (SoeRequired).
std::shared_ptr< STTx const > tx_
The underlying transaction object being wrapped.
TransactionBase(std::shared_ptr< STTx const > tx)
Construct a transaction wrapper from an existing STTx object.
TransactionBuilderBase()=default
ConfidentialMPTClawbackBuilder & sign(PublicKey const &publicKey, SecretKey const &secretKey)
TxType
Transaction type identifiers.