20 #ifndef RIPPLE_TX_IMPL_DETAILS_NFTOKENUTILS_H_INCLUDED
21 #define RIPPLE_TX_IMPL_DETAILS_NFTOKENUTILS_H_INCLUDED
23 #include <ripple/basics/base_uint.h>
24 #include <ripple/basics/tagged_integer.h>
25 #include <ripple/ledger/ApplyView.h>
26 #include <ripple/protocol/AccountID.h>
27 #include <ripple/protocol/TER.h>
28 #include <ripple/protocol/nft.h>
39 Keylet
const& directory,
50 AccountID
const& owner,
104 #endif // RIPPLE_TX_IMPL_DETAILS_NFTOKENUTILS_H_INCLUDED
std::shared_ptr< SLE > page
std::optional< TokenAndPage > findTokenAndPage(ApplyView &view, AccountID const &owner, uint256 const &nftokenID)
Finds the token in the owner's token directory.
std::size_t removeTokenOffersWithLimit(ApplyView &view, Keylet const &directory, std::size_t maxDeletableOffers)
Delete up to a specified number of offers from the specified token offer directory.
TER notTooManyOffers(ReadView const &view, uint256 const &nftokenID)
Returns tesSUCCESS if NFToken has few enough offers that it can be burned.
std::optional< STObject > findToken(ReadView const &view, AccountID const &owner, uint256 const &nftokenID)
Finds the specified token in the owner's token directory.
TER removeToken(ApplyView &view, AccountID const &owner, uint256 const &nftokenID)
Remove the token from the owner's token directory.
bool compareTokens(uint256 const &a, uint256 const &b)
Writeable view to a ledger, for applying a transaction.
Integers of any length that is a multiple of 32-bits.
TokenAndPage(STObject const &token_, std::shared_ptr< SLE > page_)
TERSubset< CanCvtToTER > TER
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
TER insertToken(ApplyView &view, AccountID owner, STObject &&nft)
Insert the token in the owner's token directory.
bool deleteTokenOffer(ApplyView &view, std::shared_ptr< SLE > const &offer)
Deletes the given token offer.