Electroneum
Loading...
Searching...
No Matches
tools::error::tx_too_big Struct Reference

#include <wallet_errors.h>

Inheritance diagram for tools::error::tx_too_big:
Collaboration diagram for tools::error::tx_too_big:

Public Member Functions

 tx_too_big (std::string &&loc, const cryptonote::transaction &tx, uint64_t tx_weight_limit)
 tx_too_big (std::string &&loc, uint64_t tx_weight, uint64_t tx_weight_limit)
bool tx_valid () const
const cryptonote::transactiontx () const
uint64_t tx_weight () const
uint64_t tx_weight_limit () const
std::string to_string () const
Public Member Functions inherited from tools::error::wallet_error_base< std::logic_error >
const std::string & location () const
std::string to_string () const

Additional Inherited Members

Protected Member Functions inherited from tools::error::transfer_error
 transfer_error (std::string &&loc, const std::string &message)
Protected Member Functions inherited from tools::error::wallet_error_base< std::logic_error >
 wallet_error_base (std::string &&loc, const std::string &message)

Detailed Description

Definition at line 722 of file wallet_errors.h.

Constructor & Destructor Documentation

◆ tx_too_big() [1/2]

tools::error::tx_too_big::tx_too_big ( std::string && loc,
const cryptonote::transaction & tx,
uint64_t tx_weight_limit )
inlineexplicit

Definition at line 724 of file wallet_errors.h.

725 : transfer_error(std::move(loc), "transaction is too big")
726 , m_tx(tx)
727 , m_tx_valid(true)
729 , m_tx_weight_limit(tx_weight_limit)
730 {
731 }
uint64_t get_transaction_weight(const transaction &tx, size_t blob_size)
transfer_error(std::string &&loc, const std::string &message)
const cryptonote::transaction & tx() const
uint64_t tx_weight_limit() const
Here is the call graph for this function:

◆ tx_too_big() [2/2]

tools::error::tx_too_big::tx_too_big ( std::string && loc,
uint64_t tx_weight,
uint64_t tx_weight_limit )
inlineexplicit

Definition at line 733 of file wallet_errors.h.

734 : transfer_error(std::move(loc), "transaction would be too big")
735 , m_tx_valid(false)
736 , m_tx_weight(tx_weight)
737 , m_tx_weight_limit(tx_weight_limit)
738 {
739 }
uint64_t tx_weight() const
Here is the call graph for this function:

Member Function Documentation

◆ to_string()

std::string tools::error::tx_too_big::to_string ( ) const
inline

Definition at line 746 of file wallet_errors.h.

747 {
748 std::ostringstream ss;
750 ", tx_weight_limit = " << m_tx_weight_limit <<
751 ", tx weight = " << m_tx_weight;
752 if (m_tx_valid)
753 {
754 cryptonote::transaction tx = m_tx;
755 ss << ", tx:\n" << cryptonote::obj_to_json_str(tx);
756 }
757 return ss.str();
758 }
std::string obj_to_json_str(T &obj)
Here is the call graph for this function:

◆ tx()

const cryptonote::transaction & tools::error::tx_too_big::tx ( ) const
inline

Definition at line 742 of file wallet_errors.h.

742{ return m_tx; }
Here is the caller graph for this function:

◆ tx_valid()

bool tools::error::tx_too_big::tx_valid ( ) const
inline

Definition at line 741 of file wallet_errors.h.

741{ return m_tx_valid; }

◆ tx_weight()

uint64_t tools::error::tx_too_big::tx_weight ( ) const
inline

Definition at line 743 of file wallet_errors.h.

743{ return m_tx_weight; }
Here is the caller graph for this function:

◆ tx_weight_limit()

uint64_t tools::error::tx_too_big::tx_weight_limit ( ) const
inline

Definition at line 744 of file wallet_errors.h.

744{ return m_tx_weight_limit; }
Here is the caller graph for this function:

The documentation for this struct was generated from the following file:
  • /home/abuild/rpmbuild/BUILD/electroneum-5.1.3.1-build/electroneum-5.1.3.1/src/wallet/wallet_errors.h