20#ifndef RIPPLE_SHAMAP_SHAMAPACCOUNTSTATELEAFNODE_H_INCLUDED
21#define RIPPLE_SHAMAP_SHAMAPACCOUNTSTATELEAFNODE_H_INCLUDED
23#include <xrpld/shamap/SHAMapItem.h>
24#include <xrpld/shamap/SHAMapLeafNode.h>
26#include <xrpl/basics/CountedObject.h>
27#include <xrpl/protocol/HashPrefix.h>
28#include <xrpl/protocol/digest.h>
39 boost::intrusive_ptr<SHAMapItem const> item,
47 boost::intrusive_ptr<SHAMapItem const> item,
57 return intr_ptr::make_shared<SHAMapAccountStateLeafNode>(
77 s.addRaw(
item_->slice());
78 s.addBitString(
item_->key());
86 s.addRaw(
item_->slice());
87 s.addBitString(
item_->key());
Tracks the number of instances of an object.
A leaf node for a state object.
SHAMapAccountStateLeafNode(boost::intrusive_ptr< SHAMapItem const > item, std::uint32_t cowid)
SHAMapAccountStateLeafNode(boost::intrusive_ptr< SHAMapItem const > item, std::uint32_t cowid, SHAMapHash const &hash)
void serializeForWire(Serializer &s) const final override
Serialize the node in a format appropriate for sending over the wire.
SHAMapNodeType getType() const final override
Determines the type of node.
void updateHash() final override
Recalculate the hash of this node.
void serializeWithPrefix(Serializer &s) const final override
Serialize the node in a format appropriate for hashing.
intr_ptr::SharedPtr< SHAMapTreeNode > clone(std::uint32_t cowid) const final override
Make a copy of this node, setting the owner.
boost::intrusive_ptr< SHAMapItem const > item_
A shared intrusive pointer class that supports weak pointers.
std::uint32_t cowid() const
Returns the SHAMap that owns this node.
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
static constexpr unsigned char const wireTypeAccountState
sha512_half_hasher::result_type sha512Half(Args const &... args)
Returns the SHA512-Half of a series of objects.