BSHA3  0.17.99
P2P Blockchain, based on Bitcoin
Public Member Functions | Public Attributes | Static Private Attributes | List of all members
CMerkleTx Class Reference

A transaction with a merkle branch linking it to the block chain. More...

#include <wallet.h>

Inheritance diagram for CMerkleTx:
[legend]
Collaboration diagram for CMerkleTx:
[legend]

Public Member Functions

 CMerkleTx ()
 
 CMerkleTx (CTransactionRef arg)
 
void Init ()
 
void SetTx (CTransactionRef arg)
 
template<typename Stream , typename Operation >
void SerializationOp (Stream &s, Operation ser_action)
 
void SetMerkleBranch (const CBlockIndex *pIndex, int posInBlock)
 
int GetDepthInMainChain () const EXCLUSIVE_LOCKS_REQUIRED(cs_main)
 Return depth of transaction in blockchain: <0 : conflicts with a transaction this deep in the blockchain 0 : in memory pool, waiting to be included in a block >=1 : this many blocks deep in the main chain. More...
 
bool IsInMainChain () const EXCLUSIVE_LOCKS_REQUIRED(cs_main)
 
int GetBlocksToMaturity () const EXCLUSIVE_LOCKS_REQUIRED(cs_main)
 
bool hashUnset () const
 
bool isAbandoned () const
 
void setAbandoned ()
 
const uint256GetHash () const
 
bool IsCoinBase () const
 
bool IsImmatureCoinBase () const EXCLUSIVE_LOCKS_REQUIRED(cs_main)
 

Public Attributes

CTransactionRef tx
 
uint256 hashBlock
 
int nIndex
 
 ADD_SERIALIZE_METHODS
 

Static Private Attributes

static const uint256 ABANDON_HASH
 Constant used in hashBlock to indicate tx has been abandoned. More...
 

Detailed Description

A transaction with a merkle branch linking it to the block chain.

Definition at line 211 of file wallet.h.

Constructor & Destructor Documentation

◆ CMerkleTx() [1/2]

CMerkleTx::CMerkleTx ( )
inline

Definition at line 228 of file wallet.h.

Here is the call graph for this function:

◆ CMerkleTx() [2/2]

CMerkleTx::CMerkleTx ( CTransactionRef  arg)
inlineexplicit

Definition at line 234 of file wallet.h.

Here is the call graph for this function:

Member Function Documentation

◆ GetBlocksToMaturity()

int CMerkleTx::GetBlocksToMaturity ( ) const
Returns
number of blocks to maturity for this transaction: 0 : is not a coinbase transaction, or is a mature coinbase transaction >0 : is a coinbase transaction which matures in this many blocks

Definition at line 4246 of file wallet.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetDepthInMainChain()

int CMerkleTx::GetDepthInMainChain ( ) const

Return depth of transaction in blockchain: <0 : conflicts with a transaction this deep in the blockchain 0 : in memory pool, waiting to be included in a block >=1 : this many blocks deep in the main chain.

Definition at line 4231 of file wallet.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetHash()

const uint256& CMerkleTx::GetHash ( ) const
inline

Definition at line 283 of file wallet.h.

Here is the caller graph for this function:

◆ hashUnset()

bool CMerkleTx::hashUnset ( ) const
inline

Definition at line 279 of file wallet.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Init()

void CMerkleTx::Init ( )
inline

Definition at line 240 of file wallet.h.

Here is the caller graph for this function:

◆ isAbandoned()

bool CMerkleTx::isAbandoned ( ) const
inline

Definition at line 280 of file wallet.h.

Here is the caller graph for this function:

◆ IsCoinBase()

bool CMerkleTx::IsCoinBase ( ) const
inline

Definition at line 284 of file wallet.h.

Here is the caller graph for this function:

◆ IsImmatureCoinBase()

bool CMerkleTx::IsImmatureCoinBase ( ) const

Definition at line 4255 of file wallet.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ IsInMainChain()

bool CMerkleTx::IsInMainChain ( ) const
inline

Definition at line 271 of file wallet.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SerializationOp()

template<typename Stream , typename Operation >
void CMerkleTx::SerializationOp ( Stream &  s,
Operation  ser_action 
)
inline

Definition at line 254 of file wallet.h.

◆ setAbandoned()

void CMerkleTx::setAbandoned ( )
inline

Definition at line 281 of file wallet.h.

◆ SetMerkleBranch()

void CMerkleTx::SetMerkleBranch ( const CBlockIndex pIndex,
int  posInBlock 
)

Definition at line 4222 of file wallet.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetTx()

void CMerkleTx::SetTx ( CTransactionRef  arg)
inline

Definition at line 246 of file wallet.h.

Here is the caller graph for this function:

Member Data Documentation

◆ ABANDON_HASH

const uint256 CMerkleTx::ABANDON_HASH
staticprivate

Constant used in hashBlock to indicate tx has been abandoned.

Definition at line 215 of file wallet.h.

◆ ADD_SERIALIZE_METHODS

CMerkleTx::ADD_SERIALIZE_METHODS

Definition at line 251 of file wallet.h.

◆ hashBlock

uint256 CMerkleTx::hashBlock

Definition at line 219 of file wallet.h.

◆ nIndex

int CMerkleTx::nIndex

Definition at line 226 of file wallet.h.

◆ tx

CTransactionRef CMerkleTx::tx

Definition at line 218 of file wallet.h.


The documentation for this class was generated from the following files: