#include <amount.h>
#include <stdint.h>
#include <vector>
Go to the source code of this file.
|
bool | Consensus::CheckTxInputs (const CTransaction &tx, CValidationState &state, const CCoinsViewCache &inputs, int nSpendHeight, CAmount &txfee) |
|
unsigned int | GetLegacySigOpCount (const CTransaction &tx) |
|
unsigned int | GetP2SHSigOpCount (const CTransaction &tx, const CCoinsViewCache &mapInputs) |
|
int64_t | GetTransactionSigOpCost (const CTransaction &tx, const CCoinsViewCache &inputs, int flags) |
|
bool | IsFinalTx (const CTransaction &tx, int nBlockHeight, int64_t nBlockTime) |
|
std::pair< int, int64_t > | CalculateSequenceLocks (const CTransaction &tx, int flags, std::vector< int > *prevHeights, const CBlockIndex &block) |
|
bool | EvaluateSequenceLocks (const CBlockIndex &block, std::pair< int, int64_t > lockPair) |
|
bool | SequenceLocks (const CTransaction &tx, int flags, std::vector< int > *prevHeights, const CBlockIndex &block) |
|
◆ CalculateSequenceLocks()
Calculates the block height and previous block's median time past at which the transaction will be considered final in the context of BIP 68. Also removes from the vector of input heights any entries which did not correspond to sequence locked inputs as they do not affect the calculation.
◆ EvaluateSequenceLocks()
bool EvaluateSequenceLocks |
( |
const CBlockIndex & |
block, |
|
|
std::pair< int, int64_t > |
lockPair |
|
) |
| |
◆ GetLegacySigOpCount()
Auxiliary functions for transaction validation (ideally should not be exposed) Count ECDSA signature operations the old-fashioned (pre-0.6) way
- Returns
- number of sigops this transaction's outputs will produce when spent
- See also
- CTransaction::FetchInputs
◆ GetP2SHSigOpCount()
Count ECDSA signature operations in pay-to-script-hash inputs.
- Parameters
-
[in] | mapInputs | Map of previous transactions that have outputs we're spending |
- Returns
- maximum number of sigops required to validate this transaction's inputs
- See also
- CTransaction::FetchInputs
◆ GetTransactionSigOpCost()
Compute total signature operation cost of a transaction.
- Parameters
-
[in] | tx | Transaction for which we are computing the cost |
[in] | inputs | Map of previous transactions that have outputs we're spending |
[out] | flags | Script verification flags |
- Returns
- Total signature operation cost of tx
◆ IsFinalTx()
Check if transaction is final and can be included in a block with the specified height and time. Consensus critical.
◆ SequenceLocks()
bool SequenceLocks |
( |
const CTransaction & |
tx, |
|
|
int |
flags, |
|
|
std::vector< int > * |
prevHeights, |
|
|
const CBlockIndex & |
block |
|
) |
| |
Check if transaction is final per BIP 68 sequence numbers and can be included in a block. Consensus critical. Takes as input a list of heights at which tx's inputs (in order) confirmed.