20 #ifndef RIPPLE_PROTOCOL_STPATHSET_H_INCLUDED
21 #define RIPPLE_PROTOCOL_STPATHSET_H_INCLUDED
23 #include <ripple/json/json_value.h>
24 #include <ripple/protocol/SField.h>
25 #include <ripple/protocol/STBase.h>
26 #include <ripple/protocol/UintTypes.h>
69 bool forceCurrency =
false);
135 template <
typename... Args>
224 template <
typename... Args>
284 , mAccountID(account)
285 , mCurrencyID(currency)
287 , is_offer_(
isXRP(mAccountID))
292 if (forceCurrency || !
isXRP(currency))
307 , mAccountID(account)
308 , mCurrencyID(currency)
310 , is_offer_(
isXRP(mAccountID))
400 return mPath.empty();
409 template <
typename... Args>
413 mPath.emplace_back(std::forward<Args>(args)...);
419 return mPath.begin();
443 return mPath.front();
486 return value.begin();
504 return value.empty();
513 template <
typename... Args>
517 value.emplace_back(std::forward<Args>(args)...);
void push_back(STPathElement const &e)
STPathElement & operator=(STPathElement const &)=default
static std::size_t get_hash(STPathElement const &element)
bool operator==(const STPathElement &t) const
std::vector< STPathElement >::size_type size() const
std::vector< STPathElement > mPath
SerializedTypeID getSType() const override
Currency const & getCurrency() const
std::vector< STPathElement >::const_reference front() const
STBase * copy(std::size_t n, void *buf) const override
void emplace_back(Args &&... args)
std::vector< STPath >::const_reference operator[](std::vector< STPath >::size_type n) const
std::vector< STPath >::const_iterator end() const
bool isEquivalent(const STBase &t) const override
std::vector< STPath >::size_type size() const
std::vector< STPathElement >::const_reference back() const
void add(Serializer &s) const override
void emplace_back(Args &&... args)
bool isDefault() const override
bool isXRP(AccountID const &c)
bool operator!=(const STPathElement &t) const
STPathElement & operator[](int i)
AccountID const & getIssuerID() const
Json::Value getJson(JsonOptions) const
bool hasSeen(AccountID const &account, Currency const ¤cy, AccountID const &issuer) const
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
std::vector< STPathElement >::const_iterator begin() const
std::vector< STPath > value
A type which can be exported to a well known binary format.
std::vector< STPath >::const_iterator begin() const
std::vector< STPathElement >::const_iterator end() const
Json::Value getJson(JsonOptions) const override
bool operator==(STPath const &t) const
bool assembleAdd(STPath const &base, STPathElement const &tail)
AccountID const & noAccount()
A placeholder for empty accounts.
STBase * move(std::size_t n, void *buf) override
void push_back(STPath const &e)
AccountID const & getAccountID() const