Basic transaction serialization format: - uint32_t version - std::vector<CTxIn> vin - std::vector<CTxOut> vout - uint32_t nLockTime
Declared in <primitives/transaction.h>
template<
typename Stream,
typename TxType>
void
UnserializeTransaction(
TxType& tx,
Stream& s,
TransactionSerParams const& params);
Extended transaction serialization format:
uint32_t version
unsigned char dummy = 0x00
unsigned char flags (!= 0)
std::vector<CTxIn> vin
std::vector<CTxOut> vout
if (flags & 1):
CScriptWitness scriptWitness; (deserialized into CTxIn)
uint32_t nLockTime
| Name | Description |
|---|---|
| tx | The transaction to populate from the stream. |
| s | The stream to read from. |
| params | Parameters controlling whether witness data is read. |