![]() |
PIVX Core
5.6.99
P2P Digital Currency
|
The basic transaction that is broadcasted on the network and contained in blocks. More...
#include <transaction.h>
Public Types | |
| enum | TxVersion : int16_t { LEGACY = 1 , SAPLING = 3 , TOOHIGH } |
| Transaction Versions. More... | |
| enum | TxType : int16_t { NORMAL = 0 , PROREG = 1 , PROUPSERV = 2 , PROUPREG = 3 , PROUPREV = 4 , LLMQCOMM = 5 } |
| Transaction types. More... | |
Public Member Functions | |
| CTransaction () | |
| Construct a CTransaction that qualifies as IsNull() More... | |
| CTransaction (const CMutableTransaction &tx) | |
| Convert a CMutableTransaction into a CTransaction. More... | |
| CTransaction (CMutableTransaction &&tx) | |
| CTransaction (const CTransaction &tx)=default | |
| template<typename Stream > | |
| void | Serialize (Stream &s) const |
| template<typename Stream > | |
| CTransaction (deserialize_type, Stream &s) | |
| This deserializing constructor is provided instead of an Unserialize method. More... | |
| bool | IsNull () const |
| const uint256 & | GetHash () const |
| bool | hasSaplingData () const |
| bool | isSaplingVersion () const |
| bool | IsShieldedTx () const |
| bool | hasExtraPayload () const |
| bool | IsSpecialTx () const |
| bool | IsNormalType () const |
| bool | IsProRegTx () const |
| bool | IsQuorumCommitmentTx () const |
| SigVersion | GetRequiredSigVersion () const |
| CAmount | GetValueOut () const |
| CAmount | GetShieldedValueIn () const |
| bool | HasZerocoinSpendInputs () const |
| bool | HasZerocoinMintOutputs () const |
| bool | ContainsZerocoins () const |
| bool | IsCoinBase () const |
| bool | IsCoinStake () const |
| bool | HasP2CSOutputs () const |
| bool | HasExchangeAddr () const |
| unsigned int | GetTotalSize () const |
| std::string | ToString () const |
| size_t | DynamicMemoryUsage () const |
Public Attributes | |
| std::vector< CTxIn > | vin |
| std::vector< CTxOut > | vout |
| const int16_t | nVersion |
| const int16_t | nType |
| const uint32_t | nLockTime |
| Optional< SaplingTxData > | sapData {SaplingTxData()} |
| Optional< std::vector< uint8_t > > | extraPayload {nullopt} |
Static Public Attributes | |
| static const int16_t | CURRENT_VERSION = TxVersion::LEGACY |
Private Member Functions | |
| uint256 | ComputeHash () const |
Private Attributes | |
| const uint256 | hash |
| Memory only. More... | |
Friends | |
| bool | operator== (const CTransaction &a, const CTransaction &b) |
| bool | operator!= (const CTransaction &a, const CTransaction &b) |
The basic transaction that is broadcasted on the network and contained in blocks.
A transaction can contain multiple inputs and outputs.
Definition at line 243 of file transaction.h.
| enum CTransaction::TxType : int16_t |
Transaction types.
| Enumerator | |
|---|---|
| NORMAL | |
| PROREG | |
| PROUPSERV | |
| PROUPREG | |
| PROUPREV | |
| LLMQCOMM | |
Definition at line 254 of file transaction.h.
| enum CTransaction::TxVersion : int16_t |
Transaction Versions.
| Enumerator | |
|---|---|
| LEGACY | |
| SAPLING | |
| TOOHIGH | |
Definition at line 247 of file transaction.h.
| CTransaction::CTransaction | ( | ) |
Construct a CTransaction that qualifies as IsNull()
Definition at line 112 of file transaction.cpp.
| CTransaction::CTransaction | ( | const CMutableTransaction & | tx | ) |
Convert a CMutableTransaction into a CTransaction.
Definition at line 113 of file transaction.cpp.
| CTransaction::CTransaction | ( | CMutableTransaction && | tx | ) |
Definition at line 114 of file transaction.cpp.
|
default |
|
inline |
This deserializing constructor is provided instead of an Unserialize method.
Unserialize is not possible, since it would require overwriting const fields.
Definition at line 295 of file transaction.h.
|
private |
|
inline |
Definition at line 371 of file transaction.h.
| size_t CTransaction::DynamicMemoryUsage | ( | ) | const |
Definition at line 106 of file transaction.cpp.
|
inline |
|
inline |
Definition at line 347 of file transaction.h.
| CAmount CTransaction::GetShieldedValueIn | ( | ) | const |
| unsigned int CTransaction::GetTotalSize | ( | ) | const |
| CAmount CTransaction::GetValueOut | ( | ) | const |
| bool CTransaction::HasExchangeAddr | ( | ) | const |
Definition at line 146 of file transaction.cpp.
|
inline |
| bool CTransaction::HasP2CSOutputs | ( | ) | const |
Definition at line 151 of file transaction.cpp.
|
inline |
| bool CTransaction::HasZerocoinMintOutputs | ( | ) | const |
| bool CTransaction::HasZerocoinSpendInputs | ( | ) | const |
|
inline |
| bool CTransaction::IsCoinStake | ( | ) | const |
|
inline |
Definition at line 334 of file transaction.h.
|
inline |
Definition at line 297 of file transaction.h.
|
inline |
|
inline |
Definition at line 341 of file transaction.h.
|
inline |
|
inline |
Definition at line 319 of file transaction.h.
|
inline |
Definition at line 329 of file transaction.h.
|
inline |
| std::string CTransaction::ToString | ( | ) | const |
Definition at line 208 of file transaction.cpp.
|
friend |
Definition at line 390 of file transaction.h.
|
friend |
Definition at line 385 of file transaction.h.
|
static |
Definition at line 263 of file transaction.h.
| Optional<std::vector<uint8_t> > CTransaction::extraPayload {nullopt} |
Definition at line 276 of file transaction.h.
|
private |
Memory only.
Definition at line 403 of file transaction.h.
| const uint32_t CTransaction::nLockTime |
Definition at line 274 of file transaction.h.
| const int16_t CTransaction::nType |
Definition at line 273 of file transaction.h.
| const int16_t CTransaction::nVersion |
Definition at line 272 of file transaction.h.
| Optional<SaplingTxData> CTransaction::sapData {SaplingTxData()} |
Definition at line 275 of file transaction.h.
| std::vector<CTxIn> CTransaction::vin |
Definition at line 270 of file transaction.h.
| std::vector<CTxOut> CTransaction::vout |
Definition at line 271 of file transaction.h.