1#ifndef XRPL_PROTOCOL_SOTEMPLATE_H_INCLUDED
2#define XRPL_PROTOCOL_SOTEMPLATE_H_INCLUDED
4#include <xrpl/basics/contract.h>
5#include <xrpl/protocol/SField.h>
44 nm +=
": '" + fieldName.
getName() +
"'";
45 Throw<std::runtime_error>(
46 "SField (" + nm +
") in SOElement must be useful.");
std::string const & getName() const
An element in a SOTemplate.
void init(SField const &fieldName) const
SOETxMPTIssue supportMPT() const
SOETxMPTIssue supportMpt_
SField const & sField() const
std::reference_wrapper< SField const > sField_
SOElement(TypedField< T > const &fieldName, SOEStyle style, SOETxMPTIssue supportMpt=soeMPTNotSupported)
SOElement(SField const &fieldName, SOEStyle style)
Defines the fields and their attributes within a STObject.
std::vector< int > indices_
int getIndex(SField const &) const
Retrieve the position of a named field.
std::vector< SOElement >::const_iterator end() const
SOTemplate(SOTemplate &&other)=default
std::vector< SOElement >::const_iterator cend() const
SOEStyle style(SField const &sf) const
std::size_t size() const
The number of entries in this template.
std::vector< SOElement >::const_iterator cbegin() const
std::vector< SOElement >::const_iterator begin() const
std::vector< SOElement > elements_
SOTemplate & operator=(SOTemplate &&other)=default
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
SOEStyle
Kind of element in each entry of an SOTemplate.
SOETxMPTIssue
Amount fields that can support MPT.
A field with a type known at compile time.