31 m_stateRoot = (
h256)r[0];
32 m_gasUsed = (
u256)r[1];
34 for (
auto const& i: r[3])
35 m_log.emplace_back(i);
41 m_bloom(eth::
bloom(_log)),
55 _out <<
"Root: " << _r.
stateRoot() << std::endl;
56 _out <<
"Gas used: " << _r.
gasUsed() << std::endl;
57 _out <<
"Logs: " << _r.
log().size() <<
" entries:" << std::endl;
60 _out <<
"Address " << i.address <<
". Topics:" << std::endl;
61 for (
auto const& j: i.topics)
62 _out <<
" " << j << std::endl;
63 _out <<
" Data: " <<
toHex(i.data) << std::endl;
65 _out <<
"Bloom: " << _r.
bloom() << std::endl;
Adapted from code found on http://stackoverflow.com/questions/180947/base64-decode-snippet-in-c Origi...
std::string toHex(T const &_data, int _w=2, HexPrefix _prefix=HexPrefix::DontAdd)
LogBloom const & bloom() const
std::ostream & operator<<(std::ostream &_out, BlockHeader const &_bi)
h256 const & stateRoot() const
std::hash for asio::adress
u256 const & gasUsed() const
RLPStream & appendList(size_t _items)
Appends a list.
boost::multiprecision::number< boost::multiprecision::cpp_int_backend< 256, 256, boost::multiprecision::unsigned_magnitude, boost::multiprecision::unchecked, void >> u256
void streamRLP(RLPStream &_s) const
h2048 LogBloom
The log bloom's size (2048-bit).
Class for writing to an RLP bytestream.
Class for interpreting Recursive Linear-Prefix Data.
std::vector< LogEntry > LogEntries
LogBloom bloom(LogEntries const &_logs)
LogEntries const & log() const