veriblock-pop-cpp
C++11 Libraries for leveraging VeriBlock Proof-Of-Proof blockchain technology.
altintegration::btc::BlockTransactions Struct Reference

Detailed Description

Definition at line 330 of file net_entities.hpp.

+ Collaboration diagram for altintegration::btc::BlockTransactions:

Public Member Functions

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

Public Attributes

uint256 blockhash
 
std::vector< Transactiontxn
 
 ADD_SERIALIZE_METHODS
 

Friends

bool operator== (const BlockTransactions &a, const BlockTransactions &b)
 
bool operator!= (const BlockTransactions &a, const BlockTransactions &b)
 

Member Function Documentation

◆ SerializationOp()

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

Definition at line 338 of file net_entities.hpp.

338 {
339 READWRITE(this->blockhash);
340 uint64_t txn_size = (uint64_t)this->txn.size();
341 READWRITE(COMPACTSIZE(txn_size));
342 if (ser_action.ForRead()) {
343 size_t i = 0;
344 while (this->txn.size() < txn_size) {
345 this->txn.resize(
346 std::min((uint64_t)(1000 + this->txn.size()), txn_size));
347 for (; i < this->txn.size(); i++) {
348 READWRITE(this->txn[i]);
349 }
350 }
351 } else {
352 for (size_t i = 0; i < txn.size(); i++) {
353 READWRITE(this->txn[i]);
354 }
355 }
356 }

Friends And Related Function Documentation

◆ operator!=

bool operator!= ( const BlockTransactions a,
const BlockTransactions b 
)
friend

Definition at line 362 of file net_entities.hpp.

363 {
364 return !(a == b);
365 }

◆ operator==

bool operator== ( const BlockTransactions a,
const BlockTransactions b 
)
friend

Definition at line 358 of file net_entities.hpp.

359 {
360 return a.blockhash == b.blockhash && a.txn == b.txn;
361 }

Member Data Documentation

◆ ADD_SERIALIZE_METHODS

altintegration::btc::BlockTransactions::ADD_SERIALIZE_METHODS

Definition at line 335 of file net_entities.hpp.

◆ blockhash

uint256 altintegration::btc::BlockTransactions::blockhash

Definition at line 332 of file net_entities.hpp.

◆ txn

std::vector<Transaction> altintegration::btc::BlockTransactions::txn

Definition at line 333 of file net_entities.hpp.


The documentation for this struct was generated from the following file: