20 #ifndef RIPPLE_SHAMAP_SHAMAPTXLEAFNODE_H_INCLUDED
21 #define RIPPLE_SHAMAP_SHAMAPTXLEAFNODE_H_INCLUDED
23 #include <ripple/basics/CountedObject.h>
24 #include <ripple/protocol/HashPrefix.h>
25 #include <ripple/protocol/digest.h>
26 #include <ripple/shamap/SHAMapItem.h>
27 #include <ripple/shamap/SHAMapLeafNode.h>
28 #include <ripple/shamap/SHAMapNodeID.h>
38 boost::intrusive_ptr<SHAMapItem const> item,
46 boost::intrusive_ptr<SHAMapItem const> item,
75 s.addRaw(
item_->slice());
83 s.addRaw(
item_->slice());
std::uint32_t cowid() const
Returns the SHAMap that owns this node.
SHAMapNodeType getType() const final override
Determines the type of node.
Tracks the number of instances of an object.
std::shared_ptr< SHAMapTreeNode > clone(std::uint32_t cowid) const final override
Make a copy of this node, setting the owner.
static constexpr unsigned const char wireTypeTransaction
A leaf node for a transaction.
void serializeForWire(Serializer &s) const final override
Serialize the node in a format appropriate for sending over the wire.
SHAMapTxLeafNode(boost::intrusive_ptr< SHAMapItem const > item, std::uint32_t cowid, SHAMapHash const &hash)
@ transactionID
transaction plus signature to give transaction ID
boost::intrusive_ptr< SHAMapItem const > item_
SHAMapTxLeafNode(boost::intrusive_ptr< SHAMapItem const > item, std::uint32_t cowid)
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
sha512_half_hasher::result_type sha512Half(Args const &... args)
Returns the SHA512-Half of a series of objects.
void serializeWithPrefix(Serializer &s) const final override
Serialize the node in a format appropriate for hashing.
void updateHash() final override
Recalculate the hash of this node.